class Platforms::Yammer::Api::GroupMemberships

Group memberships in Yammer @author Benjamin Elias @since 0.1.0

Public Instance Methods

delete(group_id, options={}) click to toggle source

Leave a Group @param group_id [#to_s] ID of Group to leave @param options [Hash] Options for the request @param headers [Hash] Additional headers to send with the request @return [Faraday::Response] the API response @see developer.yammer.com/docs/group_membershipsjsongroup_idid-1

# File lib/platforms/yammer/api/group_memberships.rb, line 26
def delete group_id, options={}, headers={}
  params = options.merge({group_id: group_id})
  @connection.delete 'group_memberships.json', params, headers
end
post(group_id, options={}) click to toggle source

Join a Group @param group_id [#to_s] The ID of the Group to join @param options [Hash] Options for the request @param headers [Hash] Additional headers to send with the request @return [Faraday::Response] the API response @see developer.yammer.com/docs/group_membershipsjsongroup_idid

# File lib/platforms/yammer/api/group_memberships.rb, line 15
def post group_id, options={}, headers={}
  body = options.merge({ group_id: group_id})
  @connection.post 'group_memberships.json', body, headers
end