Access denied due to invalid subscription key (Face API)

后端 未结 5 1253
渐次进展
渐次进展 2020-12-10 13:16

I am having trouble using Microsoft Face API. Below is my sample request:

curl -v -X POST \"https://westus.api.cognitive.microsoft.com/face/v1.0/detect?retur         


        
5条回答
  •  醉话见心
    2020-12-10 13:45

    I ran into the same problem. I read the API documentation and it states the following.

    You must use the same region in your REST API call as you used to obtain your subscription keys.

    First, you must find the location of your subscription. In order to find the location of your subscription region, you must go to Cognitive Services -> Properties under the Label Location, you will find your subscription region. See below.

    Second you must find the correct endpoint to make the call to. For example, if I want to make a call to the Computer Vision API, My location is East US, I will use either key 1 or 2, then I will use the following endpoint East US - https://eastus.api.cognitive.microsoft.com/face/v1.0/detect

    You will now be able to have access to the API.

提交回复
热议问题