Documentation
¶
Overview ¶
Package slackmsg implements the Messenger handler of Slack for Telepathy framework. Needed configs:
- CLIENT_ID: The client ID of slack app
- CLIENT_SECRET: The client secret of slack app
- SIGNING_SECRET: Used to verify the integrity of requests from Slack. It can be found in Slack app management panel
Index ¶
- type Messenger
- func (m *Messenger) AttachOutMsgChannel(ch <-chan telepathy.OutboundMessage)
- func (m *Messenger) DBRequestChannel() <-chan telepathy.DatabaseRequest
- func (m *Messenger) ID() string
- func (m *Messenger) InMsgChannel() <-chan telepathy.InboundMessage
- func (m *Messenger) SetLogger(logger *logrus.Entry)
- func (m *Messenger) SetWebhookURL(map[string]*url.URL)
- func (m *Messenger) Start()
- func (m *Messenger) Stop()
- func (m *Messenger) Webhook() map[string]telepathy.HTTPHandler
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Messenger ¶
type Messenger struct { SigningSecret []byte ClientID string ClientSecret string // contains filtered or unexported fields }
Messenger defines the plugin structure
func (*Messenger) AttachOutMsgChannel ¶
func (m *Messenger) AttachOutMsgChannel(ch <-chan telepathy.OutboundMessage)
AttachOutMsgChannel implements telepathy.PluginMessenger
func (*Messenger) DBRequestChannel ¶
func (m *Messenger) DBRequestChannel() <-chan telepathy.DatabaseRequest
DBRequestChannel implements PluginDatabaseUser
func (*Messenger) InMsgChannel ¶
func (m *Messenger) InMsgChannel() <-chan telepathy.InboundMessage
InMsgChannel implements telepathy.PluginMessenger
func (*Messenger) SetWebhookURL ¶
SetWebhookURL implements telepathy.PluginWebhookHandler
Click to show internal directories.
Click to hide internal directories.