Skip to content

[Storage] Revise Get-AzStorageAccount help example #2 #19300

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Aug 25, 2022
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 9 additions & 3 deletions src/Storage/Storage.Management/help/Get-AzStorageAccountKey.md
Original file line number Diff line number Diff line change
Expand Up @@ -33,11 +33,17 @@ This command gets the keys for the specified Azure Storage account.
### Example 2: Get a specific access key for a Storage account
<!-- Skip: Output cannot be splitted from code -->
```
This command gets a specific key for a Storage account. This command works for Azure PowerShell version 1.4, and later versions.
This command gets a specific key for a Storage account.
PS C:\>(Get-AzStorageAccountKey -ResourceGroupName "RG01" -Name "mystorageaccount")| Where-Object {$_.KeyName -eq "key1"}

This command gets a specific key for a Storage account. This command works for Azure PowerShell version 1.3.2, and previous versions.
PS C:\>(Get-AzStorageAccountKey -ResourceGroupName "RG01" -Name "mystorageaccount").Key1
KeyName Value Permissions CreationTime
------- ----- ----------- ------------
key1 <KeyValue> Full

This command gets a specific key value for a Storage account.
PS C:\>(Get-AzStorageAccountKey -ResourceGroupName "RG01" -Name "mystorageaccount")[0].Value

<KeyValue>
```

### Example 3: Lists the access keys for a Storage account, include the Kerberos keys (if active directory enabled)
Expand Down