小编Ahm*_*han的帖子

由于订阅密钥无效而拒绝访问(Face API)

我在使用Microsoft Face API时遇到问题.以下是我的示例请求:

curl -v -X POST "https://westus.api.cognitive.microsoft.com/face/v1.0/detect?returnFaceId=true&returnFaceLandmarks=false&returnFaceAttributes=age,gender" -H "Content-Type: application/json" -H "Ocp-Apim-Subscription-Key: 1xxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxd" --data-ascii "{\"url\":\"http://www.mrbeantvseries.co.uk/bean3.jpg\"}"
Run Code Online (Sandbox Code Playgroud)

我使用来自我的认知服务帐户的订阅ID,我收到以下回复:

{
  "error": {
    "code": "Unspecified",
    "message": "Access denied due to invalid subscription key. Make sure you are subscribed to an API you are trying to call and provide the right key."
  }
}
Run Code Online (Sandbox Code Playgroud)

不确定我是否错过了那里的任何东西.有人可以帮我吗?非常感谢.

face-detection microsoft-cognitive face-api

11
推荐指数
3
解决办法
1万
查看次数