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

Commit

Permalink
Generated from dc6eeefac40f35620e785bd22e81c8dc97984c79 (#3174)
Browse files Browse the repository at this point in the history
KV multiapi Readme
  • Loading branch information
AutorestCI authored Jul 26, 2018
1 parent 82b0239 commit 057a2c5
Show file tree
Hide file tree
Showing 16 changed files with 1,487 additions and 306 deletions.
42 changes: 21 additions & 21 deletions lib/services/keyVaultManagement/LICENSE.txt
Original file line number Diff line number Diff line change
@@ -1,21 +1,21 @@
The MIT License (MIT)

Copyright (c) 2017 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.
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,10 @@

import { ServiceClientCredentials } from 'ms-rest';
import { AzureServiceClient, AzureServiceClientOptions } from 'ms-rest-azure';
import * as models from "./models";
import * as operations from "./operations";

declare class KeyVaultManagementClient extends AzureServiceClient {
export default class KeyVaultManagementClient extends AzureServiceClient {
/**
* Initializes a new instance of the KeyVaultManagementClient class.
* @constructor
Expand Down Expand Up @@ -59,4 +60,4 @@ declare class KeyVaultManagementClient extends AzureServiceClient {
operations: operations.Operations;
}

export = KeyVaultManagementClient;
export { KeyVaultManagementClient, models as KeyVaultManagementModels };
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ class KeyVaultManagementClient extends ServiceClient {

super(credentials, options);

this.apiVersion = '2016-10-01';
this.apiVersion = '2018-02-14';
this.acceptLanguage = 'en-US';
this.longRunningOperationRetryTimeout = 30;
this.generateClientRequestId = true;
Expand Down Expand Up @@ -81,3 +81,6 @@ class KeyVaultManagementClient extends ServiceClient {
}

module.exports = KeyVaultManagementClient;
module.exports['default'] = KeyVaultManagementClient;
module.exports.KeyVaultManagementClient = KeyVaultManagementClient;
module.exports.KeyVaultManagementModels = models;
55 changes: 55 additions & 0 deletions lib/services/keyVaultManagement/lib/models/iPRule.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,55 @@
/*
* Copyright (c) Microsoft Corporation. All rights reserved.
* Licensed under the MIT License. See License.txt in the project root for
* license information.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is
* regenerated.
*/

'use strict';

/**
* A rule governing the accesibility of a vault from a specific ip address or
* ip range.
*
*/
class IPRule {
/**
* Create a IPRule.
* @member {string} value An IPv4 address range in CIDR notation, such as
* '124.56.78.91' (simple IP address) or '124.56.78.0/24' (all addresses that
* start with 124.56.78).
*/
constructor() {
}

/**
* Defines the metadata of IPRule
*
* @returns {object} metadata of IPRule
*
*/
mapper() {
return {
required: false,
serializedName: 'IPRule',
type: {
name: 'Composite',
className: 'IPRule',
modelProperties: {
value: {
required: true,
serializedName: 'value',
type: {
name: 'String'
}
}
}
}
};
}
}

module.exports = IPRule;
171 changes: 144 additions & 27 deletions lib/services/keyVaultManagement/lib/models/index.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,57 @@ export interface AccessPolicyEntry {
permissions: Permissions;
}

/**
* @class
* Initializes a new instance of the IPRule class.
* @constructor
* A rule governing the accesibility of a vault from a specific ip address or
* ip range.
*
* @member {string} value An IPv4 address range in CIDR notation, such as
* '124.56.78.91' (simple IP address) or '124.56.78.0/24' (all addresses that
* start with 124.56.78).
*/
export interface IPRule {
value: string;
}

/**
* @class
* Initializes a new instance of the VirtualNetworkRule class.
* @constructor
* A rule governing the accesibility of a vault from a specific virtual
* network.
*
* @member {string} id Full resource id of a vnet subnet, such as
* '/subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Network/virtualNetworks/test-vnet/subnets/subnet1'.
*/
export interface VirtualNetworkRule {
id: string;
}

/**
* @class
* Initializes a new instance of the NetworkRuleSet class.
* @constructor
* A set of rules governing the network accessibility of a vault.
*
* @member {string} [bypass] Tells what traffic can bypass network rules. This
* can be 'AzureServices' or 'None'. If not specified the default is
* 'AzureServices'. Possible values include: 'AzureServices', 'None'
* @member {string} [defaultAction] The default action when no rule from
* ipRules and from virtualNetworkRules match. This is only used after the
* bypass property has been evaluated. Possible values include: 'Allow', 'Deny'
* @member {array} [ipRules] The list of IP address rules.
* @member {array} [virtualNetworkRules] The list of virtual network rules.
*/
export interface NetworkRuleSet {
bypass?: string;
defaultAction?: string;
ipRules?: IPRule[];
virtualNetworkRules?: VirtualNetworkRule[];
}

/**
* @class
* Initializes a new instance of the VaultProperties class.
Expand All @@ -101,11 +152,9 @@ export interface AccessPolicyEntry {
* unwrap keys.
* @member {boolean} [enabledForTemplateDeployment] Property to specify whether
* Azure Resource Manager is permitted to retrieve secrets from the key vault.
* @member {boolean} [enableSoftDelete] Property specifying whether recoverable
* deletion is enabled for this key vault. Setting this property to true
* activates the soft delete feature, whereby vaults or vault entities can be
* recovered after deletion. Enabling this functionality is irreversible - that
* is, the property does not accept false as its value.
* @member {boolean} [enableSoftDelete] Property to specify whether the 'soft
* delete' functionality is enabled for this key vault. It does not accept
* false value.
* @member {string} [createMode] The vault's create mode to indicate whether
* the vault need to be recovered or not. Possible values include: 'recover',
* 'default'
Expand All @@ -116,6 +165,17 @@ export interface AccessPolicyEntry {
* setting is effective only if soft delete is also enabled. Enabling this
* functionality is irreversible - that is, the property does not accept false
* as its value.
* @member {object} [networkAcls] A collection of rules governing the
* accessibility of the vault from specific network locations.
* @member {string} [networkAcls.bypass] Tells what traffic can bypass network
* rules. This can be 'AzureServices' or 'None'. If not specified the default
* is 'AzureServices'. Possible values include: 'AzureServices', 'None'
* @member {string} [networkAcls.defaultAction] The default action when no rule
* from ipRules and from virtualNetworkRules match. This is only used after the
* bypass property has been evaluated. Possible values include: 'Allow', 'Deny'
* @member {array} [networkAcls.ipRules] The list of IP address rules.
* @member {array} [networkAcls.virtualNetworkRules] The list of virtual
* network rules.
*/
export interface VaultProperties {
tenantId: string;
Expand All @@ -128,6 +188,7 @@ export interface VaultProperties {
enableSoftDelete?: boolean;
createMode?: string;
enablePurgeProtection?: boolean;
networkAcls?: NetworkRuleSet;
}

/**
Expand All @@ -153,16 +214,30 @@ export interface VaultProperties {
* unwrap keys.
* @member {boolean} [enabledForTemplateDeployment] Property to specify whether
* Azure Resource Manager is permitted to retrieve secrets from the key vault.
* @member {boolean} [enableSoftDelete] Property specifying whether recoverable
* deletion ('soft' delete) is enabled for this key vault. The property may not
* be set to false.
* @member {boolean} [enableSoftDelete] Property to specify whether the 'soft
* delete' functionality is enabled for this key vault. It does not accept
* false value.
* @member {string} [createMode] The vault's create mode to indicate whether
* the vault need to be recovered or not. Possible values include: 'recover',
* 'default'
* @member {boolean} [enablePurgeProtection] Property specifying whether
* protection against purge is enabled for this vault; it is only effective if
* soft delete is also enabled. Once activated, the property may no longer be
* reset to false.
* protection against purge is enabled for this vault. Setting this property to
* true activates protection against purge for this vault and its content -
* only the Key Vault service may initiate a hard, irrecoverable deletion. The
* setting is effective only if soft delete is also enabled. Enabling this
* functionality is irreversible - that is, the property does not accept false
* as its value.
* @member {object} [networkAcls] A collection of rules governing the
* accessibility of the vault from specific network locations.
* @member {string} [networkAcls.bypass] Tells what traffic can bypass network
* rules. This can be 'AzureServices' or 'None'. If not specified the default
* is 'AzureServices'. Possible values include: 'AzureServices', 'None'
* @member {string} [networkAcls.defaultAction] The default action when no rule
* from ipRules and from virtualNetworkRules match. This is only used after the
* bypass property has been evaluated. Possible values include: 'Allow', 'Deny'
* @member {array} [networkAcls.ipRules] The list of IP address rules.
* @member {array} [networkAcls.virtualNetworkRules] The list of virtual
* network rules.
*/
export interface VaultPatchProperties {
tenantId?: string;
Expand All @@ -174,6 +249,7 @@ export interface VaultPatchProperties {
enableSoftDelete?: boolean;
createMode?: string;
enablePurgeProtection?: boolean;
networkAcls?: NetworkRuleSet;
}

/**
Expand Down Expand Up @@ -240,11 +316,9 @@ export interface DeletedVaultProperties {
* @member {boolean} [properties.enabledForTemplateDeployment] Property to
* specify whether Azure Resource Manager is permitted to retrieve secrets from
* the key vault.
* @member {boolean} [properties.enableSoftDelete] Property specifying whether
* recoverable deletion is enabled for this key vault. Setting this property to
* true activates the soft delete feature, whereby vaults or vault entities can
* be recovered after deletion. Enabling this functionality is irreversible -
* that is, the property does not accept false as its value.
* @member {boolean} [properties.enableSoftDelete] Property to specify whether
* the 'soft delete' functionality is enabled for this key vault. It does not
* accept false value.
* @member {string} [properties.createMode] The vault's create mode to indicate
* whether the vault need to be recovered or not. Possible values include:
* 'recover', 'default'
Expand All @@ -255,6 +329,20 @@ export interface DeletedVaultProperties {
* deletion. The setting is effective only if soft delete is also enabled.
* Enabling this functionality is irreversible - that is, the property does not
* accept false as its value.
* @member {object} [properties.networkAcls] A collection of rules governing
* the accessibility of the vault from specific network locations.
* @member {string} [properties.networkAcls.bypass] Tells what traffic can
* bypass network rules. This can be 'AzureServices' or 'None'. If not
* specified the default is 'AzureServices'. Possible values include:
* 'AzureServices', 'None'
* @member {string} [properties.networkAcls.defaultAction] The default action
* when no rule from ipRules and from virtualNetworkRules match. This is only
* used after the bypass property has been evaluated. Possible values include:
* 'Allow', 'Deny'
* @member {array} [properties.networkAcls.ipRules] The list of IP address
* rules.
* @member {array} [properties.networkAcls.virtualNetworkRules] The list of
* virtual network rules.
*/
export interface VaultCreateOrUpdateParameters extends BaseResource {
location: string;
Expand Down Expand Up @@ -288,16 +376,33 @@ export interface VaultCreateOrUpdateParameters extends BaseResource {
* @member {boolean} [properties.enabledForTemplateDeployment] Property to
* specify whether Azure Resource Manager is permitted to retrieve secrets from
* the key vault.
* @member {boolean} [properties.enableSoftDelete] Property specifying whether
* recoverable deletion ('soft' delete) is enabled for this key vault. The
* property may not be set to false.
* @member {boolean} [properties.enableSoftDelete] Property to specify whether
* the 'soft delete' functionality is enabled for this key vault. It does not
* accept false value.
* @member {string} [properties.createMode] The vault's create mode to indicate
* whether the vault need to be recovered or not. Possible values include:
* 'recover', 'default'
* @member {boolean} [properties.enablePurgeProtection] Property specifying
* whether protection against purge is enabled for this vault; it is only
* effective if soft delete is also enabled. Once activated, the property may
* no longer be reset to false.
* whether protection against purge is enabled for this vault. Setting this
* property to true activates protection against purge for this vault and its
* content - only the Key Vault service may initiate a hard, irrecoverable
* deletion. The setting is effective only if soft delete is also enabled.
* Enabling this functionality is irreversible - that is, the property does not
* accept false as its value.
* @member {object} [properties.networkAcls] A collection of rules governing
* the accessibility of the vault from specific network locations.
* @member {string} [properties.networkAcls.bypass] Tells what traffic can
* bypass network rules. This can be 'AzureServices' or 'None'. If not
* specified the default is 'AzureServices'. Possible values include:
* 'AzureServices', 'None'
* @member {string} [properties.networkAcls.defaultAction] The default action
* when no rule from ipRules and from virtualNetworkRules match. This is only
* used after the bypass property has been evaluated. Possible values include:
* 'Allow', 'Deny'
* @member {array} [properties.networkAcls.ipRules] The list of IP address
* rules.
* @member {array} [properties.networkAcls.virtualNetworkRules] The list of
* virtual network rules.
*/
export interface VaultPatchParameters extends BaseResource {
tags?: { [propertyName: string]: string };
Expand Down Expand Up @@ -376,11 +481,9 @@ export interface Resource extends BaseResource {
* @member {boolean} [properties.enabledForTemplateDeployment] Property to
* specify whether Azure Resource Manager is permitted to retrieve secrets from
* the key vault.
* @member {boolean} [properties.enableSoftDelete] Property specifying whether
* recoverable deletion is enabled for this key vault. Setting this property to
* true activates the soft delete feature, whereby vaults or vault entities can
* be recovered after deletion. Enabling this functionality is irreversible -
* that is, the property does not accept false as its value.
* @member {boolean} [properties.enableSoftDelete] Property to specify whether
* the 'soft delete' functionality is enabled for this key vault. It does not
* accept false value.
* @member {string} [properties.createMode] The vault's create mode to indicate
* whether the vault need to be recovered or not. Possible values include:
* 'recover', 'default'
Expand All @@ -391,6 +494,20 @@ export interface Resource extends BaseResource {
* deletion. The setting is effective only if soft delete is also enabled.
* Enabling this functionality is irreversible - that is, the property does not
* accept false as its value.
* @member {object} [properties.networkAcls] A collection of rules governing
* the accessibility of the vault from specific network locations.
* @member {string} [properties.networkAcls.bypass] Tells what traffic can
* bypass network rules. This can be 'AzureServices' or 'None'. If not
* specified the default is 'AzureServices'. Possible values include:
* 'AzureServices', 'None'
* @member {string} [properties.networkAcls.defaultAction] The default action
* when no rule from ipRules and from virtualNetworkRules match. This is only
* used after the bypass property has been evaluated. Possible values include:
* 'Allow', 'Deny'
* @member {array} [properties.networkAcls.ipRules] The list of IP address
* rules.
* @member {array} [properties.networkAcls.virtualNetworkRules] The list of
* virtual network rules.
*/
export interface Vault extends Resource {
properties: VaultProperties;
Expand Down
3 changes: 3 additions & 0 deletions lib/services/keyVaultManagement/lib/models/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,9 @@ exports.CloudError = msRestAzure.CloudError;
exports.Sku = require('./sku');
exports.Permissions = require('./permissions');
exports.AccessPolicyEntry = require('./accessPolicyEntry');
exports.IPRule = require('./iPRule');
exports.VirtualNetworkRule = require('./virtualNetworkRule');
exports.NetworkRuleSet = require('./networkRuleSet');
exports.VaultProperties = require('./vaultProperties');
exports.VaultPatchProperties = require('./vaultPatchProperties');
exports.VaultAccessPolicyProperties = require('./vaultAccessPolicyProperties');
Expand Down
Loading

0 comments on commit 057a2c5

Please sign in to comment.