Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions packages/@azure/arm-keyvault/lib/keyVaultManagementClient.ts
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ class KeyVaultManagementClient extends KeyVaultManagementClientContext {
// Operation groups
vaults: operations.Vaults;
operations: operations.Operations;
secrets: operations.Secrets;

/**
* Initializes a new instance of the KeyVaultManagementClient class.
Expand All @@ -31,6 +32,7 @@ class KeyVaultManagementClient extends KeyVaultManagementClientContext {
super(credentials, subscriptionId, options);
this.vaults = new operations.Vaults(this);
this.operations = new operations.Operations(this);
this.secrets = new operations.Secrets(this);
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ export class KeyVaultManagementClientContext extends msRestAzure.AzureServiceCli

super(credentials, options);

this.apiVersion = '2018-02-14';
this.apiVersion = '2019-00-00';
this.acceptLanguage = 'en-US';
this.longRunningOperationRetryTimeout = 30;
this.baseUri = options.baseUri || this.baseUri || "https://management.azure.com";
Expand Down
277 changes: 277 additions & 0 deletions packages/@azure/arm-keyvault/lib/models/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -646,6 +646,160 @@ export interface Operation {
serviceSpecification?: ServiceSpecification;
}

/**
* @interface
* An interface representing Attributes.
* The object attributes managed by the KeyVault service.
*
*/
export interface Attributes {
/**
* @member {boolean} [enabled] Determines whether the object is enabled.
*/
enabled?: boolean;
/**
* @member {Date} [notBefore] Not before date in UTC.
*/
notBefore?: Date;
/**
* @member {Date} [expires] Expiry date in UTC.
*/
expires?: Date;
/**
* @member {Date} [created] Creation time in UTC.
* **NOTE: This property will not be serialized. It can only be populated by
* the server.**
*/
readonly created?: Date;
/**
* @member {Date} [updated] Last updated time in UTC.
* **NOTE: This property will not be serialized. It can only be populated by
* the server.**
*/
readonly updated?: Date;
}

/**
* @interface
* An interface representing SecretAttributes.
* The secret management attributes.
*
* @extends Attributes
*/
export interface SecretAttributes extends Attributes {
}

/**
* @interface
* An interface representing SecretProperties.
* Properties of the secret
*
*/
export interface SecretProperties {
/**
* @member {string} [value] The value of the secret. NOTE: 'value' will never
* be returned from the service, as APIs using this model are is intended for
* internal use in ARM deployments. Users should use the data-plane REST
* service for interaction with vault secrets.
*/
value?: string;
/**
* @member {string} [contentType] The content type of the secret.
*/
contentType?: string;
/**
* @member {SecretAttributes} [attributes] The attributes of the secret.
*/
attributes?: SecretAttributes;
/**
* @member {string} [secretUri] The URI to retrieve the current version of
* the secret.
* **NOTE: This property will not be serialized. It can only be populated by
* the server.**
*/
readonly secretUri?: string;
/**
* @member {string} [secretUriWithVersion] The URI to retrieve the specific
* version of the secret.
* **NOTE: This property will not be serialized. It can only be populated by
* the server.**
*/
readonly secretUriWithVersion?: string;
}

/**
* @interface
* An interface representing SecretPatchProperties.
* Properties of the secret
*
*/
export interface SecretPatchProperties {
/**
* @member {string} [value] The value of the secret.
*/
value?: string;
/**
* @member {string} [contentType] The content type of the secret.
*/
contentType?: string;
/**
* @member {SecretAttributes} [attributes] The attributes of the secret.
*/
attributes?: SecretAttributes;
}

/**
* @interface
* An interface representing SecretCreateOrUpdateParameters.
* Parameters for creating or updating a secret
*
* @extends BaseResource
*/
export interface SecretCreateOrUpdateParameters extends BaseResource {
/**
* @member {{ [propertyName: string]: string }} [tags] The tags that will be
* assigned to the secret.
*/
tags?: { [propertyName: string]: string };
/**
* @member {SecretProperties} properties Properties of the secret
*/
properties: SecretProperties;
}

/**
* @interface
* An interface representing SecretPatchParameters.
* Parameters for patching a secret
*
* @extends BaseResource
*/
export interface SecretPatchParameters extends BaseResource {
/**
* @member {{ [propertyName: string]: string }} [tags] The tags that will be
* assigned to the secret.
*/
tags?: { [propertyName: string]: string };
/**
* @member {SecretPatchProperties} [properties] Properties of the secret
*/
properties?: SecretPatchProperties;
}

/**
* @interface
* An interface representing Secret.
* Resource information with extended details.
*
* @extends Resource
*/
export interface Secret extends Resource {
/**
* @member {SecretProperties} properties Properties of the secret
*/
properties: SecretProperties;
}

/**
* @interface
* An interface representing VaultsListByResourceGroupOptionalParams.
Expand Down Expand Up @@ -688,6 +842,20 @@ export interface VaultsListOptionalParams extends msRest.RequestOptionsBase {
top?: number;
}

/**
* @interface
* An interface representing SecretsListOptionalParams.
* Optional Parameters.
*
* @extends RequestOptionsBase
*/
export interface SecretsListOptionalParams extends msRest.RequestOptionsBase {
/**
* @member {number} [top] Maximum number of results to return.
*/
top?: number;
}

/**
* @interface
* An interface representing KeyVaultManagementClientOptions.
Expand Down Expand Up @@ -759,6 +927,20 @@ export interface OperationListResult extends Array<Operation> {
nextLink?: string;
}

/**
* @interface
* An interface representing the SecretListResult.
* List of secrets
*
* @extends Array<Secret>
*/
export interface SecretListResult extends Array<Secret> {
/**
* @member {string} [nextLink] The URL to get the next set of secrets.
*/
nextLink?: string;
}

/**
* Defines values for SkuName.
* Possible values include: 'standard', 'premium'
Expand Down Expand Up @@ -1165,3 +1347,98 @@ export type OperationsListNextResponse = OperationListResult & {
parsedBody: OperationListResult;
};
};

/**
* Contains response data for the createOrUpdate operation.
*/
export type SecretsCreateOrUpdateResponse = Secret & {
/**
* The underlying HTTP response.
*/
_response: msRest.HttpResponse & {
/**
* The response body as text (string format)
*/
bodyAsText: string;
/**
* The response body as parsed JSON or XML
*/
parsedBody: Secret;
};
};

/**
* Contains response data for the update operation.
*/
export type SecretsUpdateResponse = Secret & {
/**
* The underlying HTTP response.
*/
_response: msRest.HttpResponse & {
/**
* The response body as text (string format)
*/
bodyAsText: string;
/**
* The response body as parsed JSON or XML
*/
parsedBody: Secret;
};
};

/**
* Contains response data for the get operation.
*/
export type SecretsGetResponse = Secret & {
/**
* The underlying HTTP response.
*/
_response: msRest.HttpResponse & {
/**
* The response body as text (string format)
*/
bodyAsText: string;
/**
* The response body as parsed JSON or XML
*/
parsedBody: Secret;
};
};

/**
* Contains response data for the list operation.
*/
export type SecretsListResponse = SecretListResult & {
/**
* The underlying HTTP response.
*/
_response: msRest.HttpResponse & {
/**
* The response body as text (string format)
*/
bodyAsText: string;
/**
* The response body as parsed JSON or XML
*/
parsedBody: SecretListResult;
};
};

/**
* Contains response data for the listNext operation.
*/
export type SecretsListNextResponse = SecretListResult & {
/**
* The underlying HTTP response.
*/
_response: msRest.HttpResponse & {
/**
* The response body as text (string format)
*/
bodyAsText: string;
/**
* The response body as parsed JSON or XML
*/
parsedBody: SecretListResult;
};
};
Loading