File size: 687 Bytes
1e92f2d
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
package mockslack

import (
	"net/http"
)

// ServeAuthTest serves a request to the `auth.test` API call.
//
// https://slack.com/api/auth.test
func (s *Server) ServeAuthTest(w http.ResponseWriter, req *http.Request) {
	var respData struct {
		OK                  bool   `json:"ok"`
		URL                 string `json:"url"`
		Team                string `json:"team"`
		User                string `json:"user"`
		TeamID              string `json:"team_id"`
		UserID              string `json:"user_id"`
		BotID               string `json:"bot_id"`
		IsEnterpriseInstall bool   `json:"is_enterprise_install"`
	}
	respData.OK = true
	respData.TeamID = s.teamID
	respondWith(w, respData)
}