Share via


KeyVaultClientExtensions.RecoverDeletedSecretAsync Method

Definition

Overloads

RecoverDeletedSecretAsync(IKeyVaultClient, String, CancellationToken)

Recovers the deleted secret.

RecoverDeletedSecretAsync(IKeyVaultClient, String, String, CancellationToken)

Recovers the deleted secret to the latest version.

RecoverDeletedSecretAsync(IKeyVaultClient, String, CancellationToken)

Source:
KeyVaultClientExtensions.cs

Recovers the deleted secret.

public static System.Threading.Tasks.Task<Microsoft.Azure.KeyVault.Models.SecretBundle> RecoverDeletedSecretAsync (this Microsoft.Azure.KeyVault.IKeyVaultClient operations, string recoveryId, System.Threading.CancellationToken cancellationToken = default);
static member RecoverDeletedSecretAsync : Microsoft.Azure.KeyVault.IKeyVaultClient * string * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Microsoft.Azure.KeyVault.Models.SecretBundle>
<Extension()>
Public Function RecoverDeletedSecretAsync (operations As IKeyVaultClient, recoveryId As String, Optional cancellationToken As CancellationToken = Nothing) As Task(Of SecretBundle)

Parameters

operations
IKeyVaultClient
recoveryId
String

The recoveryId of the deleted secret, returned from deletion.

cancellationToken
CancellationToken

Optional cancellation token

Returns

A response message containing the recovered secret

Applies to

RecoverDeletedSecretAsync(IKeyVaultClient, String, String, CancellationToken)

Source:
KeyVaultClientExtensions.cs

Recovers the deleted secret to the latest version.

public static System.Threading.Tasks.Task<Microsoft.Azure.KeyVault.Models.SecretBundle> RecoverDeletedSecretAsync (this Microsoft.Azure.KeyVault.IKeyVaultClient operations, string vaultBaseUrl, string secretName, System.Threading.CancellationToken cancellationToken = default);
static member RecoverDeletedSecretAsync : Microsoft.Azure.KeyVault.IKeyVaultClient * string * string * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Microsoft.Azure.KeyVault.Models.SecretBundle>
<Extension()>
Public Function RecoverDeletedSecretAsync (operations As IKeyVaultClient, vaultBaseUrl As String, secretName As String, Optional cancellationToken As CancellationToken = Nothing) As Task(Of SecretBundle)

Parameters

operations
IKeyVaultClient

The operations group for this extension method.

vaultBaseUrl
String

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

secretName
String

The name of the deleted secret.

cancellationToken
CancellationToken

The cancellation token.

Returns

Remarks

Recovers the deleted secret in the specified vault. This operation can only be performed on a soft-delete enabled vault. This operation requires the secrets/recover permission.

Applies to