Sha256: b91cdfe51cae38808de0af89513cc3d0c2c5f520e87cdd33ba0d1b34acef0e02
Contents?: true
Size: 668 Bytes
Versions: 1
Compression:
Stored size: 668 Bytes
Contents
module Goodreads module Authors # Get author details # def author(id, params = {}) params[:id] = id data = request("/author/show", params) Hashie::Mash.new(data["author"]) end # Get an author's books # def author_books(id, params = {}) params[:id] = id data = request("/author/list", params) Hashie::Mash.new(data["author"]) end # Search for an author by name # def author_by_name(name, params = {}) params[:id] = name name_encoded = URI.encode(name) data = request("/api/author_url/#{name_encoded}", params) Hashie::Mash.new(data["author"]) end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
goodreads-0.9.0 | lib/goodreads/client/authors.rb |