Get-AzCognitiveServicesAccountKey
取得帳戶的 API 金鑰。
語法
Get-AzCognitiveServicesAccountKey
[-ResourceGroupName] <String>
[-Name] <String>
[-DefaultProfile <IAzureContextContainer>]
[<CommonParameters>]
Description
Get-AzCognitiveServicesAccountKey Cmdlet 會取得已佈建認知服務帳戶的 API 密鑰。 認知服務帳戶有兩個 API 金鑰:Key1 和 Key2。 金鑰可啟用與認知服務帳戶端點的互動。 使用 New-AzCognitiveServicesAccountKey 重新產生金鑰。
範例
範例 1
Get-AzCognitiveServicesAccountKey -ResourceGroupName cognitive-services-resource-group -name myluis
Key1 Key2
---- ----
xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
參數
-DefaultProfile
用於與 azure 通訊的認證、帳戶、租用戶和訂用帳戶
類型: | IAzureContextContainer |
別名: | AzContext, AzureRmContext, AzureCredential |
Position: | Named |
預設值: | None |
必要: | False |
接受管線輸入: | False |
接受萬用字元: | False |
-Name
指定帳戶的名稱。 此 Cmdlet 會取得此帳戶的金鑰。
類型: | String |
別名: | CognitiveServicesAccountName, AccountName |
Position: | 1 |
預設值: | None |
必要: | True |
接受管線輸入: | True |
接受萬用字元: | False |
-ResourceGroupName
指定指派帳戶的資源群組名稱。
類型: | String |
Position: | 0 |
預設值: | None |
必要: | True |
接受管線輸入: | True |
接受萬用字元: | False |