I using Google Vision OCR to get text from image with PHP language. When i used in a long time. I get error below:
array(1) {
["error"]=>
array(4) {
["code"]=>
int(403)
["message"]=>
string(53) "Requests from IP address ..... are blocked."
["status"]=>
string(17) "PERMISSION_DENIED"
["details"]=>
array(1) {
[0]=>
array(2) {
["@type"]=>
string(35) "type.googleapis.com/google.rpc.Help"
["links"]=>
array(1) {
[0]=>
array(2) {
["description"]=>
string(32) "Google developer console API key"
["url"]=>
string(75) "https://console.developers.google.com/project/191619933224/apiui/credential"
}
}
}
}
}
}
Please show me reason and how to fix it. Thank all so much.
Check that you have authorized the API in the Cloud API console and configured your PHP client as described in the sample documentation .
Specifically, make sure you download the credentials.json
file that is associated with your vision API project and set the GOOGLE_APPLICATION_CREDENTIALS
environment variable to the credential path before running the sample.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.