you can check the following discussions hope they help
401000 error when trying to use my key in python using deep_translator library
aakervall
0
Reputation points
Hello! New to python and I am trying to use the deep_translator library for Microsoft Translator. I set up an API for Microsoft Translator in Azure and am using the following code in python:
text = "You got this!"
translatedtext = MicrosoftTranslator(api_key='myAPIkey_fromAzure', target='sv').translate(text=text)
However, I'm getting the following error. I've double checked the key multiple times...
MicrosoftAPIerror: Microsoft API returned the following error: {'code': 401000, 'message': 'The request is not authorized because credentials are missing or invalid.'}
Any ideas why?