func (c client) GroupID(name string) (string, error) {
	id, err := getPubChannelID(c.conf.Token, name)
	if err == nil && id != "" {
		return id, nil
	}
	return getPrivGroupID(c.conf.Token, name)
}
GroupID returns public channel or private group id by given name
package api
import (
	"encoding/json"
	"net/http"
	"net/url"
	"reflect"
	"github.com/blinkloader/slk/errors"
)
type chanList struct {
	Ok bool `json:"ok"`
	Channels []*Channel `json:"channels"`
	Groups   []*Channel `json:"groups"`
	Ims      []*Channel `json:"ims"`
}
type Channel struct {
	ID   string `json:"id"`
	Name string `json:"name"`
	User string `json:"user"`
}
func (c client) ChannelID(name string) (id string, err error) {
	switch name[0] {
	case '@':  
		id, err = c.ImChatID(name[1:])
	default:  
		id, err = c.GroupID(name)
	}
	if err != nil {
		return "", errors.Wrap(errGetChannelID, err)
	}
	return
}
func (c client) ImChatID(name string) (string, error) {
	l, err := getChannelList(c.conf.Token, "https://slack.com/api/im.list")
	if err != nil {
		return "", err
	}
	userID, err := c.UserID(name)
	if err != nil {
		return "", err
	}
	id, err := getChannelID("User", userID, l.Ims)
	if err != nil {
		return "", err
	}
	return id, nil
}