0
votes

I am trying to upgrade my traduction API calling translate cognitive to V3.0. First thing I try is calling the api using Insomina software but I always have unauthorized responce.

I used this documentation: https://docs.microsoft.com/en-us/azure/cognitive-services/translator/reference/v3-0-reference

enter image description here

In the header, I m adding the Ocp-Apim-Subscription-Key with the key readable in the azure portal.

enter image description here

The strange point is that the endpoint given in the doc is: api-eur.cognitive.microsofttranslator.com and the one in the portal is https://westeurope.api.cognitive.microsoft.com/

Am I missing something? Thank you

1
post your endpointSajeetharan

1 Answers

1
votes

I think you are passing the Ocp-Apim-Subscription-Key directly with the request. Instead

(i)You should obtain the token by passing the url with postman as follows,

enter image description here

then you need to pass the token with the request as follows,

enter image description here