KeyClient.PurgeDeletedKeyAsync(String, CancellationToken) Method

Definition

Permanently deletes the specified key.

public virtual System.Threading.Tasks.Task<Azure.Response> PurgeDeletedKeyAsync (string name, System.Threading.CancellationToken cancellationToken = default);
abstract member PurgeDeletedKeyAsync : string * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Azure.Response>
override this.PurgeDeletedKeyAsync : string * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Azure.Response>
Public Overridable Function PurgeDeletedKeyAsync (name As String, Optional cancellationToken As CancellationToken = Nothing) As Task(Of Response)

Parameters

name
String

The name of the key.

cancellationToken
CancellationToken

A CancellationToken controlling the request lifetime.

Returns

Task<Response>

Exceptions

name is an empty string.

name is null.

The server returned an error. See Message for details returned from the server.

Remarks

The Purge Deleted Key operation is applicable for soft-delete enabled vaults. While the operation can be invoked on any vault, it will return an error if invoked on a non soft-delete enabled vault. This operation requires the keys/purge permission.

Applies to