I have this error when I am using Speech to text from azure whith free trial version : CANCELED CancellationDetails(reason=CancellationReason.Error, error_details="WebSocket upgrade failed: Authentication error (401). Please check subscription information and region name.
I created an acompt Microsoft azure and I followed the documentation for Speech service. When I created a resource I got two keys and a location.
In my code I wrote this :
speech_key, service_region = "<key>", "<location>"
speech_config = speechsdk.SpeechConfig(subscription=speech_key, region=service_region)
And when I run this code this error is displayed. I am sure that I put the correct key and location.
Do you know if I forgot something or I am doing something bad?