Cmdlets

Choose a cmdlet from the list on the left or search for a specific cmdlet. Choose a cmdlet from the list or search for a specific cmdlet.
About Help  Providers
 

Remove-AzureKeyVaultSecret

Remove-AzureKeyVaultSecret

microsoft.azure.commands.keyvault.dll

Synopsis

Deletes a secret in a vault.

Syntax

Remove-AzureKeyVaultSecret [-VaultName] [-Name] [-Force] [-PassThru] [-Profile] [<CommonParameters>]

Detailed Description

The Remove-AzureKeyVaultSecret cmdlet deletes a secret in an Azure Key Vault. This cmdlet has a value of high for the ConfirmImpact property.

Parameters

-Force <SwitchParameter>

Forces the command to run without asking for user confirmation.

Aliases

none

Required?

false

Position

named

Default value

none

Accept pipeline input?

false

Accept wildcard characters?

false

-Name <String>

Specifies the name of a secret. This cmdlet constructs the fully qualified domain name (FQDN) of a secret based on the name that this parameter specifies, the name of the vault, and your current environment.

Aliases

SecretName

Required?

true

Position

2

Default value

none

Accept pipeline input?

true(ByPropertyName)

Accept wildcard characters?

false

-PassThru <SwitchParameter>

Indicates that this cmdlet returns a Microsoft.Azure.Commands.KeyVault.Models.Secret object. By default, this cmdlet does not generate any output.

Aliases

none

Required?

false

Position

named

Default value

none

Accept pipeline input?

false

Accept wildcard characters?

false

-Profile <Microsoft.Azure.Common.Authentication.Models.AzureProfile>

Specifies the Azure profile from which this cmdlet reads. If you do not specify a profile, this cmdlet reads from the local default profile.

Aliases

none

Required?

false

Position

named

Default value

none

Accept pipeline input?

false

Accept wildcard characters?

false

-VaultName <String>

Specifies the name of the vault to which the secret belongs. This cmdlet constructs the FQDN of a vault based on the name that this parameter specifies and your current environment.

Aliases

none

Required?

true

Position

1

Default value

none

Accept pipeline input?

true(ByPropertyName)

Accept wildcard characters?

false

Input Type

String

Return Type

Microsoft.Azure.Commands.KeyVault.Models.Secret

Notes

None

Examples

Example 1: Remove a secret from a vault

This command removes the secret named FinanceSecret from the vault named Contoso.

PS C:\>Remove-AzureKeyVaultSecret -VaultName "Contoso" -Name "FinanceSecret"

Example 2: Remove a secret from a vault without user confirmation

This command removes the secret named FinanceSecret from the vault named Contoso. The command specifies the Force and Confirm parameters, and, therefore, the cmdlet does not prompt you for confirmation.

PS C:\>Remove-AzureKeyVaultSecret -VaultName "Contoso" -Name "FinanceSecret" -Force -Confirm:$False

Online Version
Get-AzureKeyVaultSecret
Set-AzureKeyVaultSecret