Codebase list golang-github-nlopes-slack / 490e02b
Support groups.info API Robert Wachs 8 years ago
1 changed file(s) with 13 addition(s) and 0 deletion(s). Raw diff Collapse all Expand all
201201 return response.Groups, nil
202202 }
203203
204 // GetGroupInfo retrieves the given group
205 func (api *Slack) GetGroupInfo(groupId string) (*Group, error) {
206 values := url.Values{
207 "token": {api.config.token},
208 "channel": {groupId},
209 }
210 response, err := groupRequest("groups.info", values, api.debug)
211 if err != nil {
212 return nil, err
213 }
214 return &response.Group, nil
215 }
216
204217 // SetGroupReadMark sets the read mark on a private group
205218 // Clients should try to avoid making this call too often. When needing to mark a read position, a client should set a
206219 // timer before making the call. In this way, any further updates needed during the timeout will not generate extra