IKeyVaultClient.UpdateSecretWithHttpMessagesAsync(String, String, String, String, SecretAttributes, IDictionary<String,String>, Dictionary<String,List<String>>, CancellationToken) Method

Definition

Updates the attributes associated with a specified secret in a given key vault.

public System.Threading.Tasks.Task<Microsoft.Rest.Azure.AzureOperationResponse<Microsoft.Azure.KeyVault.Models.SecretBundle>> UpdateSecretWithHttpMessagesAsync (string vaultBaseUrl, string secretName, string secretVersion, string contentType = null, Microsoft.Azure.KeyVault.Models.SecretAttributes secretAttributes = null, System.Collections.Generic.IDictionary<string,string> tags = null, System.Collections.Generic.Dictionary<string,System.Collections.Generic.List<string>> customHeaders = null, System.Threading.CancellationToken cancellationToken = null);
abstract member UpdateSecretWithHttpMessagesAsync : string * string * string * string * Microsoft.Azure.KeyVault.Models.SecretAttributes * System.Collections.Generic.IDictionary<string, string> * System.Collections.Generic.Dictionary<string, System.Collections.Generic.List<string>> * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Microsoft.Rest.Azure.AzureOperationResponse<Microsoft.Azure.KeyVault.Models.SecretBundle>>

Parameters

vaultBaseUrl
String

The vault name, for example https://myvault.vault.azure.net.

secretName
String

The name of the secret.

secretVersion
String

The version of the secret.

contentType
String

Type of the secret value such as a password.

secretAttributes
SecretAttributes

The secret management attributes.

tags
IDictionary<String,String>

Application specific metadata in the form of key-value pairs.

customHeaders
Dictionary<String,List<String>>

The headers that will be added to request.

cancellationToken
CancellationToken

The cancellation token.

Returns

Task<Microsoft.Rest.Azure.AzureOperationResponse<SecretBundle>>

Remarks

The UPDATE operation changes specified attributes of an existing

stored secret. Attributes that are not specified in the request are

left unchanged. The value of a secret itself cannot be changed.

Applies to