<commit_before>package main

import (
	"errors"
	"strings"
)

func (s *SlackAPI) ApiTest() {
	var response interface{}
	s.GetRequest(&response, "api.test")
	s.PrintJson(response)
}

func (s *SlackAPI) AuthTest() {
	var response interface{}
	s.GetRequest(&response, "auth.test", "token")
	s.PrintJson(response)
}

func (s *SlackAPI) ChannelsInfo(channel string) {
	var response interface{}
	s.GetRequest(&response, "channels.info", "token", "channel="+channel)
	s.PrintJson(response)
}

func (s *SlackAPI) ChannelsList() {
	var response interface{}
	s.GetRequest(&response, "channels.list", "token", "exclude_archived=0")
	s.PrintJson(response)
}

func (s *SlackAPI) ChatDeleteVerbose(channel string, timestamp string) {
	response := s.ChatDelete(channel, timestamp)
	s.PrintJson(response)
}

func (s *SlackAPI) ChatPostMessageVerbose(channel string, message string) {
	response := s.ChatPostMessage(channel, message)
	s.PrintJson(response)
}

func (s *SlackAPI) EmojiList() {
	var response interface{}
	s.GetRequest(&response, "emoji.list", "token")
	s.PrintJson(response)
}

func (s *SlackAPI) GroupsInfo(channel string) {
	var response interface{}
	s.GetRequest(&response, "groups.info", "token", "channel="+channel)
	s.PrintJson(response)
}

func (s *SlackAPI) GroupsList() {
	var response interface{}
	s.GetRequest(&response, "groups.list", "token", "exclude_archived=0")
	s.PrintJson(response)
}

func (s *SlackAPI) InstantMessagingCloseVerbose(channel string) {
	response := s.InstantMessagingClose(channel)
	s.PrintJson(response)
}

func (s *SlackAPI) InstantMessagingList() {
	var response interface{}
	s.GetRequest(&response, "im.list", "token")
	s.PrintJson(response)
}

func (s *SlackAPI) InstantMessagingOpenVerbose(userid string) {
	response := s.InstantMessagingOpen(userid)
	s.PrintJson(response)
}

func (s *SlackAPI) MultiPartyInstantMessagingList() {
	var response interface{}
	s.GetRequest(&response, "mpim.list", "token")
	s.PrintJson(response)
}

func (s *SlackAPI) ReactionsList(userid string) {
	var response interface{}

	if userid == "" {
		s.GetRequest(&response,
			"reactions.list",
			"token",
			"full=true",
			"count=100")
	} else {
		s.GetRequest(&response,
			"reactions.list",
			"token",
			"full=true",
			"count=100",
			"user="+userid)
	}
	s.PrintJson(response)
}

func (s *SlackAPI) ReactionsRemove(name string, channel string, timestamp string) {
	var response interface{}
	s.GetRequest(&response,
		"reactions.remove",
		"token",
		"name="+name,
		"channel="+channel,
		"timestamp="+timestamp)
	s.PrintJson(response)
}

func (s *SlackAPI) TeamInfo() {
	var response interface{}<commit_msg>Added support for reactions.remove method with files<commit_after>package main

import (
	"errors"
	"strings"
)

func (s *SlackAPI) ApiTest() {
	var response interface{}
	s.GetRequest(&response, "api.test")
	s.PrintJson(response)
}

func (s *SlackAPI) AuthTest() {
	var response interface{}
	s.GetRequest(&response, "auth.test", "token")
	s.PrintJson(response)
}

func (s *SlackAPI) ChannelsInfo(channel string) {
	var response interface{}
	s.GetRequest(&response, "channels.info", "token", "channel="+channel)
	s.PrintJson(response)
}

func (s *SlackAPI) ChannelsList() {
	var response interface{}
	s.GetRequest(&response, "channels.list", "token", "exclude_archived=0")
	s.PrintJson(response)
}

func (s *SlackAPI) ChatDeleteVerbose(channel string, timestamp string) {
	response := s.ChatDelete(channel, timestamp)
	s.PrintJson(response)
}

func (s *SlackAPI) ChatPostMessageVerbose(channel string, message string) {
	response := s.ChatPostMessage(channel, message)
	s.PrintJson(response)
}

func (s *SlackAPI) EmojiList() {
	var response interface{}
	s.GetRequest(&response, "emoji.list", "token")
	s.PrintJson(response)
}

func (s *SlackAPI) GroupsInfo(channel string) {
	var response interface{}
	s.GetRequest(&response, "groups.info", "token", "channel="+channel)
	s.PrintJson(response)
}

func (s *SlackAPI) GroupsList() {
	var response interface{}
	s.GetRequest(&response, "groups.list", "token", "exclude_archived=0")
	s.PrintJson(response)
}

func (s *SlackAPI) InstantMessagingCloseVerbose(channel string) {
	response := s.InstantMessagingClose(channel)
	s.PrintJson(response)
}

func (s *SlackAPI) InstantMessagingList() {
	var response interface{}
	s.GetRequest(&response, "im.list", "token")
	s.PrintJson(response)
}

func (s *SlackAPI) InstantMessagingOpenVerbose(userid string) {
	response := s.InstantMessagingOpen(userid)
	s.PrintJson(response)
}

func (s *SlackAPI) MultiPartyInstantMessagingList() {
	var response interface{}
	s.GetRequest(&response, "mpim.list", "token")
	s.PrintJson(response)
}

func (s *SlackAPI) ReactionsList(userid string) {
	var response interface{}

	if userid == "" {
		s.GetRequest(&response,
			"reactions.list",
			"token",
			"full=true",
			"count=100")
	} else {
		s.GetRequest(&response,
			"reactions.list",
			"token",
			"full=true",
			"count=100",
			"user="+userid)
	}
	s.PrintJson(response)
}

func (s *SlackAPI) ReactionsRemove(name string, channel string, timestamp string) {
	var response interface{}

	// Remove reaction from a file, file comment, or message.
	if channel[0] == 'F' {
		s.GetRequest(&response,
			"reactions.remove",
			"token",
			"name="+name,
			"file="+channel)
	} else {
		s.GetRequest(&response,
			"reactions.remove",
			"token",
			"name="+name,
			"channel="+channel,
			"timestamp="+timestamp)
	}

	s.PrintJson(response)
}

func (s *SlackAPI) TeamInfo() {
	var response interface{}
{'fraction_non_alphanumeric': 0.15427948391786298, 'fraction_numerical': 0.0030892240596038525, 'mean_word_length': 5.591616766467066, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3567404', 'n_tokens_mistral': 2039, 'n_tokens_neox': 1951, 'n_words': 415}