Module: Remind101::Client::Groups
- Included in:
- Remind101::Client
- Defined in:
- lib/remind101/client/groups.rb
Instance Method Summary collapse
-
#delete_group(group_id) ⇒ Object
Public: Destroys an existing group.
-
#get_groups(options = {}) ⇒ Object
Public: Returns all groups for the current user.
-
#post_group(hash) ⇒ Object
Public: Creates a new group.
Instance Method Details
#delete_group(group_id) ⇒ Object
Public: Destroys an existing group.
Examples
remind101.delete_group 4321
Returns the destroyed group.
32 33 34 |
# File 'lib/remind101/client/groups.rb', line 32 def delete_group(group_id) api_delete("/groups/#{group_id}") end |
#get_groups(options = {}) ⇒ Object
Public: Returns all groups for the current user.
Examples
remind101.get_groups
Returns the faraday response.
10 11 12 |
# File 'lib/remind101/client/groups.rb', line 10 def get_groups( = {}) api_get('/groups', ) end |
#post_group(hash) ⇒ Object
Public: Creates a new group.
Examples
remind101.post_group group: { name: 'Math 101' }
Returns the faraday response.
21 22 23 |
# File 'lib/remind101/client/groups.rb', line 21 def post_group(hash) api_post('/groups', hash) end |