Documentation ¶
Index ¶
- type MMClient
- func (c *MMClient) CreateDebuggingChannelIfNeeded() error
- func (c *MMClient) GetChannel(name string) (*model.Channel, *model.Response)
- func (c *MMClient) GetChannelByName(name string) (*model.Channel, error)
- func (c *MMClient) GetTeam() (*model.Team, error)
- func (c *MMClient) LoginAsUser() (*model.User, error)
- func (c *MMClient) NewWebSocketClient() (*model.WebSocketClient, error)
- func (c *MMClient) PingServer()
- func (c *MMClient) SendCmdToChannel(cmd string, channelId string, prePost *model.Post) error
- func (c *MMClient) SendMsgToChannel(msg string, channelId string, prePost *model.Post) error
- func (c *MMClient) SendMsgToDebuggingChannel(msg string, replyToId string) error
- func (c *MMClient) SetupGracefulShutdown()
- func (c *MMClient) UpdateUserIfNeeded() error
- type Server
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type MMClient ¶
type MMClient struct { Client *model.Client4 WebSocketClient *model.WebSocketClient BotUser *model.User BotTeam *model.Team DebuggingChannel *model.Channel Server Server SettingsUrl string // contains filtered or unexported fields }
func NewMMClient ¶
Documentation for the Go driver can be found at https://godoc.org/github.com/mattermost/platform/model#Client
func (*MMClient) CreateDebuggingChannelIfNeeded ¶
func (*MMClient) GetChannel ¶
This function came from the original sample code. It sucks. Use GetChannelByName instead.
func (*MMClient) GetChannelByName ¶
This function returns a proper error so you can know what the heck is going on
func (*MMClient) NewWebSocketClient ¶
func (c *MMClient) NewWebSocketClient() (*model.WebSocketClient, error)
func (*MMClient) PingServer ¶
func (c *MMClient) PingServer()
func (*MMClient) SendCmdToChannel ¶
func (*MMClient) SendMsgToChannel ¶
func (*MMClient) SendMsgToDebuggingChannel ¶
func (*MMClient) SetupGracefulShutdown ¶
func (c *MMClient) SetupGracefulShutdown()
func (*MMClient) UpdateUserIfNeeded ¶
Click to show internal directories.
Click to hide internal directories.