Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func EnvAccessor ¶
func EnvAccessor() adapter.EnvConfigAccessor
EnvAccessor for configuration parameters
func NewAdapter ¶
func NewAdapter(ctx context.Context, aEnv adapter.EnvConfigAccessor, ceClient cloudevents.Client) adapter.Adapter
NewAdapter adapter implementation
Types ¶
type SlackChallenge ¶
type SlackChallenge struct { Category string `json:"type"` Token string `json:"token"` Challenge string `json:"challenge"` }
SlackChallenge contains the handshake challenge for the Slack events API.
type SlackChallengeResponse ¶
type SlackChallengeResponse struct {
Challenge string `json:"challenge"`
}
SlackChallengeResponse is the handshake response for a challenge.
type SlackEventAPIHandler ¶
SlackEventAPIHandler listen for Slack API Events
func NewSlackEventAPIHandler ¶
func NewSlackEventAPIHandler(ceClient cloudevents.Client, port int, signingSecret, appID string, tw timeWrap, logger *zap.SugaredLogger) SlackEventAPIHandler
NewSlackEventAPIHandler creates the default implementation of the Slack API Events handler
type SlackEventWrapper ¶
type SlackEventWrapper struct { AdditionalProperties map[string]interface{} `json:"-,omitempty"` APIAppID string `json:"api_app_id"` AuthedUsers []string `json:"authed_users"` Event SlackEvent `json:"event"` EventID string `json:"event_id"` EventTime int `json:"event_time"` TeamID string `json:"team_id"` Token string `json:"token"` Type string `json:"type"` }
SlackEventWrapper contains a common wrapper for all events. See https://api.slack.com/types/event for reference.
Click to show internal directories.
Click to hide internal directories.