client.go
func (c *Client) AuthenticatePrivateChannel(params []byte) (response []byte, err error) {
	return c.authenticateChannel(params, nil)
}
func (c *Client) AuthenticatePrivateChannel(params []byte) (response []byte, err error) {
	return c.authenticateChannel(params, nil)
}
func ( c * Client ) AuthenticatePrivateChannel ( params [ ] byte ) ( response [ ] byte , err error ) { return c . authenticateChannel ( params , nil ) }
/*
Application security is very important so Pusher provides a mechanism
for authenticating a user’s access to a channel at the point of subscription.

This can be used both to restrict access to private channels,
and in the case of presence channels notify subscribers of
who else is also subscribed via presence events.

This library provides a mechanism for generating an
authentication signature to send back to the client
and authorize them.

For more information see our docs: http://pusher.com/docs/authenticating_users.

This is an example of authenticating a private-channel, using the built-in
Golang HTTP library to start a server.

In order to authorize a client, one must read the response into type `[]byte` and pass it in.
This will return a signature in the form of a `[]byte` for you to send back to the client.

	func pusherAuth(res http.ResponseWriter, req *http.Request) {

		params, _ := ioutil.ReadAll(req.Body)
		response, err := client.AuthenticatePrivateChannel(params)

		if err != nil {
			panic(err)
		}

		fmt.Fprintf(res, string(response))

	}

	func main() {
		http.HandleFunc("/pusher/auth", pusherAuth)
		http.ListenAndServe(":5000", nil)
	}

*/
/ * Application security is very important so Pusher provides a mechanism for authenticating a user’s access to a channel at the point of subscription .