KeyClient.CreateExternalKeyAsync Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Registers a Managed HSM key that points at material managed by an external HSM. This operation requires the keys/create permission. Only available with service version V2026_01_01_Preview and newer, and only supported on Managed HSM.
public virtual System.Threading.Tasks.Task<Azure.Response<Azure.Security.KeyVault.Keys.KeyVaultKey>> CreateExternalKeyAsync(Azure.Security.KeyVault.Keys.CreateExternalKeyOptions externalKeyOptions, System.Threading.CancellationToken cancellationToken = default);
abstract member CreateExternalKeyAsync : Azure.Security.KeyVault.Keys.CreateExternalKeyOptions * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Azure.Response<Azure.Security.KeyVault.Keys.KeyVaultKey>>
override this.CreateExternalKeyAsync : Azure.Security.KeyVault.Keys.CreateExternalKeyOptions * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Azure.Response<Azure.Security.KeyVault.Keys.KeyVaultKey>>
Public Overridable Function CreateExternalKeyAsync (externalKeyOptions As CreateExternalKeyOptions, Optional cancellationToken As CancellationToken = Nothing) As Task(Of Response(Of KeyVaultKey))
Parameters
- externalKeyOptions
- CreateExternalKeyOptions
The key options object containing the name and external key reference for the key being registered.
- cancellationToken
- CancellationToken
A CancellationToken controlling the request lifetime.
Returns
Exceptions
externalKeyOptions is null.
The server returned an error. See Message for details returned from the server.