Home
My Books
Browse ▾
Recommendations
Choice Awards
Genres
Giveaways
New Releases
Lists
Explore
News & Interviews
Genres
Art
Biography
Business
Children's
Christian
Classics
Comics
Cookbooks
Ebooks
Fantasy
Fiction
Graphic Novels
Historical Fiction
History
Horror
Memoir
Music
Mystery
Nonfiction
Poetry
Psychology
Romance
Science
Science Fiction
Self Help
Sports
Thriller
Travel
Young Adult
More Genres
Community ▾
Groups
Quotes
Ask the Author
Sign In
Join
Sign up
View profile
Profile
Friends
Groups
Discussions
Comments
Reading Challenge
Kindle Notes & Highlights
Quotes
Favorite genres
Friends’ recommendations
Account settings
Help
Sign out
Home
My Books
Browse ▾
Recommendations
Choice Awards
Genres
Giveaways
New Releases
Lists
Explore
News & Interviews
Genres
Art
Biography
Business
Children's
Christian
Classics
Comics
Cookbooks
Ebooks
Fantasy
Fiction
Graphic Novels
Historical Fiction
History
Horror
Memoir
Music
Mystery
Nonfiction
Poetry
Psychology
Romance
Science
Science Fiction
Self Help
Sports
Thriller
Travel
Young Adult
More Genres
Community ▾
Groups
Quotes
Ask the Author
Goodreads Developers
discussion
15 views
bugs
> Bug: data present in web interface missing from API response
Comments
Showing 1-1 of 1
(1 new)
post a comment »
date
newest »
message 1:
by
Matt
(new)
May 02, 2018 07:24AM
For some books, the edition language is correct in the web interface, but the language_code element in the API results for that book is unset.
An example:
https://www.goodreads.com/book/show/5...
shows an Edition Language of English. However,
"""
gr_key=[% key %]
get_gr_book() {
book_id=$1
gr_xml=$(curl -s
https://www.goodreads.com/book/show/$...
)
echo -n 'Author: '; echo "$gr_xml" | xml_grep --text_only //GoodreadsResponse/book/authors/author[0]/name
echo -n 'Title: '; echo "$gr_xml" | xml_grep --text_only //GoodreadsResponse/book/title
echo -n 'Language: '; echo "$gr_xml" | xml_grep --text_only //GoodreadsResponse/book/language_code
echo
}
$ get_gr_book 5968469
Author: Agnes Owens
Title: The Complete Short Stories
Language:
$
"""
This does, however, work with other books:
"""
$ get_gr_book 366649
Author: Émile Zola
Title: Le Ventre de Paris (Les Rougon-Macquart, #3)
Language: fre
$
"""
reply
|
flag
back to top
post a comment »
Add a reference:
Book
Author
Search for a book to add a reference
add:
link
cover
Author:
add:
link
photo
Share
Goodreads Developers
Group Home
Bookshelf
Discussions
Photos
Videos
Send invite
Members
Polls
unread topics
|
mark unread
Welcome back. Just a moment while we sign you in to your Goodreads account.
An example: https://www.goodreads.com/book/show/5... shows an Edition Language of English. However,
"""
gr_key=[% key %]
get_gr_book() {
book_id=$1
gr_xml=$(curl -s https://www.goodreads.com/book/show/$...)
echo -n 'Author: '; echo "$gr_xml" | xml_grep --text_only //GoodreadsResponse/book/authors/author[0]/name
echo -n 'Title: '; echo "$gr_xml" | xml_grep --text_only //GoodreadsResponse/book/title
echo -n 'Language: '; echo "$gr_xml" | xml_grep --text_only //GoodreadsResponse/book/language_code
echo
}
$ get_gr_book 5968469
Author: Agnes Owens
Title: The Complete Short Stories
Language:
$
"""
This does, however, work with other books:
"""
$ get_gr_book 366649
Author: Émile Zola
Title: Le Ventre de Paris (Les Rougon-Macquart, #3)
Language: fre
$
"""