February 28th, 2018

PowerTip: Create new authentication keys for AzureRM Cognitive Services

Doctor Scripto
Scripter

Summary: Change the keys to authenticate to Azure RM Cognitive Services, by using Windows PowerShell.

  Hey, Scripting Guy! I created the keys for my Rest API. I know I can change them in the web portal, but is there a faster way of doing it through Windows PowerShell?

  There absolutely is! Just use the New-AzureRMCognitiveServicesAccountKey cmdlet to reset either Key1 or Key2 (or both). Here is an example, where we generate a new sequence for Key1:

New-AzureRMCognitiveServicesAccountKey -ResourceGroup ‘HSG’ -Name ‘Sample’ -KeyName Key1

Author

The "Scripting Guys" is a historical title passed from scripter to scripter. The current revision has morphed into our good friend Doctor Scripto who has been with us since the very beginning.

0 comments

Discussion are closed.