当我们返回"我们目前无法访问该URL"时,我会调用google api.但资源必须存在且可以访问.
https://vision.googleapis.com/v1/images:annotate
请求内容:
{
"requests": [
{
"image": {
"source": {
"imageUri": "http://yun.jybdfx.com/static/img/homebg.jpg"
}
},
"features": [
{
"type": "TEXT_DETECTION"
}
],
"imageContext": {
"languageHints": [
"zh"
]
}
}
]
}
Run Code Online (Sandbox Code Playgroud)
回复内容:
{
"responses": [
{
"error": {
"code": 4,
"message": "We can not access the URL currently. Please download the content and pass it in."
}
}
]
}
Run Code Online (Sandbox Code Playgroud)