问题
I am trying to use Google books API but for any request I receive totalItems = 0
.
I've tried to send the request in chrome, for example:
https://www.googleapis.com/books/v1/volumes?q=flowers+inauthor:keyes&key=MY_KEY
Also I've tried the approach, described here:
https://github.com/google/google-api-java-client-samples/blob/master/books-cmdline-sample/src/main/java/com/google/api/services/samples/books/cmdline/BooksSample.java
And for any query with any parameters I always receive nothing:
{
"kind": "books#volumes",
"totalItems": 0
}
I generated key using developer console: https://console.developers.google.com and selected option Api Key.
I will appreciate any help with this issue.
Thanks in advance!
回答1:
As I've understood, the problem is in my country(Belarus). Looks like Google Books APi doesn't work in Belarus. Problem can be fixed by using VPN.
来源:https://stackoverflow.com/questions/48886400/google-books-api-always-returns-nothing