I'm trying to use the Google Vision API. I'm following getting started guide:
- I have enabled the Cloud Vision API
- I have enabled billing
- I have set up an API key
- Made base64-encoded data from my image
Made JSON file with settings:
{ "requests":[ { "image":{ "content":"my base64-encoded data" }, "features":[ { "type":"LABEL_DETECTION", "maxResults":5 } ] } ] }Sent request with
curl:$ curl -v -k -s -H "Content-Type: application/json" https://vision.googleapis.com/v1/images:annotate?key=my_browser_key --data-binary @path_to_file.json
After that I got response:
{
"error": {
"code": 403,
"message": "Requests from referer \u003cempty\u003e are blocked.",
"status": "PERMISSION_DENIED",
"details": [
{
"@type": "type.googleapis.com/google.rpc.Help",
"links": [
{
"description": "Google developer console API key",
"url": "https://console.developers.google.com/project/***********/apiui/credential"
}
]
}
]
}
}
\u003cempty\u003e means <empty>
Any ideas? Somebody have the same problem?