I have a subscription key for https://api.cognitive.microsofttranslator.com/translate?api-version=3.0&from=en&to=de

Tushar Dash 26 Reputation points
2020-10-30T06:41:14.68+00:00

I am calling this api like
https://api.cognitive.microsofttranslator.com/translate?api-version=3.0&from=en&to=de
with 'Ocp-Apim-Subscription-Key' = my subscription key. But I am getting below error

{code: 401000, message: "The request is not authorized because credentials are missing or invalid."}

Azure Translator
Azure Translator
An Azure service to easily conduct machine translation with a simple REST API call.
363 questions
0 comments No comments
{count} vote

1 answer

Sort by: Most helpful
  1. Ramr-msft 17,651 Reputation points
    2020-10-30T07:42:48.317+00:00

    @Tushar Dash , Please follow the below doc for Translator v3.0.
    https://video2.skills-academy.com/en-us/azure/cognitive-services/translator/reference/v3-0-reference#authentication

    Please find the snapshot for the same using the Ocp-Apim-Subscription-Key.

    36253-image.png