client.go
func (c *Client) Channels(additionalQueries map[string]string) (*ChannelsList, error) {
	path := fmt.Sprintf("/apps/%s/channels", c.AppId)
	u, err := createRequestURL("GET", c.Host, path, c.Key, c.Secret, authTimestamp(), c.Secure, nil, additionalQueries, c.Cluster)
	if err != nil {
		return nil, err
	}
	response, err := c.request("GET", u, nil)
	if err != nil {
		return nil, err
	}
	return unmarshalledChannelsList(response)
}
func (c *Client) Channels(additionalQueries map[string]string) (*ChannelsList, error) {
	path := fmt.Sprintf("/apps/%s/channels", c.AppId)
	u, err := createRequestURL("GET", c.Host, path, c.Key, c.Secret, authTimestamp(), c.Secure, nil, additionalQueries, c.Cluster)
	if err != nil {
		return nil, err
	}
	response, err := c.request("GET", u, nil)
	if err != nil {
		return nil, err
	}
	return unmarshalledChannelsList(response)
}
func ( c * Client ) Channels ( additionalQueries map [ string ] string ) ( * ChannelsList , error ) { path := fmt . Sprintf ( " " , c . AppId ) u , err := createRequestURL ( " " , c . Host , path , c . Key , c . Secret , authTimestamp ( ) , c . Secure , nil , additionalQueries , c . Cluster ) if err != nil { return nil , err } response , err := c . request ( " " , u , nil ) if err != nil { return nil , err } return unmarshalledChannelsList ( response ) }
/*
One can use this method to get a list of all the channels in an application.

The parameter `additionalQueries` is a map with query options. A key with `"filter_by_prefix"`
will filter the returned channels. To get number of users subscribed to a presence-channel,
specify an `"info"` key with value `"user_count"`. Pass in `nil` if you do not wish to specify any query attributes.

	channelsParams := map[string]string{
	    "filter_by_prefix": "presence-",
	    "info":             "user_count",
	}

	channels, err := client.Channels(channelsParams)

	//channels=> &{Channels:map[presence-chatroom:{UserCount:4} presence-notifications:{UserCount:31}  ]}

*/
/ * One can use this method to get a list of all the channels in an application .