Module: Goodreads::Groups
- Included in:
- Client
- Defined in:
- lib/goodreads/client/groups.rb
Instance Method Summary collapse
-
#group(group_id) ⇒ Object
Get group details.
-
#group_list(user_id, sort = 'my_activity') ⇒ Object
Get list of groups a given user is a member of.
Instance Method Details
#group(group_id) ⇒ Object
Get group details
4 5 6 7 |
# File 'lib/goodreads/client/groups.rb', line 4 def group(group_id) data = request('/group/show', :id => group_id) Hashie::Mash.new(data['group']) end |
#group_list(user_id, sort = 'my_activity') ⇒ Object
Get list of groups a given user is a member of
10 11 12 13 |
# File 'lib/goodreads/client/groups.rb', line 10 def group_list(user_id, sort='my_activity') data = request('/group/list', :id => user_id, :sort => sort) Hashie::Mash.new(data['groups']['list']) end |