slack-web-1.5.0.0: Bindings for the Slack web API
Safe HaskellSafe-Inferred
LanguageHaskell2010

Web.Slack.Experimental.Events.Types

Description

Types for the Slack Events API.

Synopsis

Documentation

data ChannelType Source #

Not a ConversationType for some mysterious reason; this one has Channel as an option, which does not exist as a ConversationType. Slack, why?

Constructors

Channel 
Group 
Im 

data MessageEvent Source #

Constructors

MessageEvent 

Fields

data MessageUpdateEvent Source #

https://api.slack.com/events/message/message_changed

FIXME(jadel): implement. This is mega cursed! in the normal message event the channel is called "channel" but here it is called "channelId" and also has a "channel_name" and "channel_team". Why?!

We don't decode these on this basis.

Constructors

MessageUpdateEvent 

data CreatedChannel Source #

FIXME: this might be a Channel, but may also be missing some fields/have bonus because Slack is cursed.

newtype EventId Source #

Constructors

EventId 

Fields

Instances

Instances details
FromJSON EventId Source # 
Instance details

Defined in Web.Slack.Experimental.Events.Types

Show EventId Source # 
Instance details

Defined in Web.Slack.Experimental.Events.Types

newtype MessageId Source #

Constructors

MessageId 

Fields

data Event Source #

Instances

Instances details
FromJSON Event Source # 
Instance details

Defined in Web.Slack.Experimental.Events.Types

Generic Event Source # 
Instance details

Defined in Web.Slack.Experimental.Events.Types

Associated Types

type Rep Event :: Type -> Type #

Methods

from :: Event -> Rep Event x #

to :: Rep Event x -> Event #

Show Event Source # 
Instance details

Defined in Web.Slack.Experimental.Events.Types

Methods

showsPrec :: Int -> Event -> ShowS #

show :: Event -> String #

showList :: [Event] -> ShowS #

type Rep Event Source # 
Instance details

Defined in Web.Slack.Experimental.Events.Types

type Rep Event = D1 ('MetaData "Event" "Web.Slack.Experimental.Events.Types" "slack-web-1.5.0.0-JuKKPWQb8GZ9iOuMskKzDQ" 'False) ((C1 ('MetaCons "EventMessage" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 MessageEvent)) :+: (C1 ('MetaCons "EventMessageChanged" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "EventChannelJoinMessage" 'PrefixI 'False) (U1 :: Type -> Type))) :+: (C1 ('MetaCons "EventChannelCreated" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 ChannelCreatedEvent)) :+: (C1 ('MetaCons "EventChannelLeft" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 ChannelLeftEvent)) :+: C1 ('MetaCons "EventUnknown" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 Value)))))

data SlackWebhookEvent Source #

Instances

Instances details
FromJSON SlackWebhookEvent Source # 
Instance details

Defined in Web.Slack.Experimental.Events.Types

Generic SlackWebhookEvent Source # 
Instance details

Defined in Web.Slack.Experimental.Events.Types

Associated Types

type Rep SlackWebhookEvent :: Type -> Type #

Show SlackWebhookEvent Source # 
Instance details

Defined in Web.Slack.Experimental.Events.Types

type Rep SlackWebhookEvent Source # 
Instance details

Defined in Web.Slack.Experimental.Events.Types

type Rep SlackWebhookEvent = D1 ('MetaData "SlackWebhookEvent" "Web.Slack.Experimental.Events.Types" "slack-web-1.5.0.0-JuKKPWQb8GZ9iOuMskKzDQ" 'False) (C1 ('MetaCons "EventUrlVerification" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 UrlVerificationPayload)) :+: (C1 ('MetaCons "EventEventCallback" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 EventCallback)) :+: C1 ('MetaCons "EventUnknownWebhook" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 Value))))

Event responses

By and large, Slack does not care about the response returned from event handlers, at least for the EventEventCallback as long as your service 200s. The exception is EventUrlVerification, which is expected to return a UrlVerificationResponse