Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func HandleFunc ¶
func HandleFunc(h HandlerFunc)
HandleFunc handles Slack Events with callback function.
Types ¶
type Event ¶
type Event struct { ChannelID string `json:"channel_id"` ChannelName string `json:"channel_name"` Command string `json:"command"` ResponseURL string `json:"response_url"` TeamDomain string `json:"team_domain"` TeamID string `json:"team_id"` Text string `json:"text"` Token string `json:"token"` UserID string `json:"user_id"` UserName string `json:"user_name"` }
Event data JSON
type HandlerFunc ¶
HandlerFunc unmarshals Slack Events before passing control.
func (HandlerFunc) Handle ¶
func (h HandlerFunc) Handle(data json.RawMessage, ctx *apex.Context) (interface{}, error)
Handle implements apex.Handler.
type ResponseMessage ¶
type ResponseMessage struct { ResponseType string `json:"response_type"` Text string `json:"text"` }
ResponseMessage JSON
Click to show internal directories.
Click to hide internal directories.