calamity-0.1.14.3: A library for writing discord bots
Safe HaskellNone
LanguageHaskell2010

Calamity.Gateway.Types

Description

Types for shards

Documentation

type ShardC r = Members '[LogEff, AtomicState ShardState, Embed IO, Final IO, Async, MetricEff] r Source #

data ShardMsg Source #

Instances

Instances details
Show ShardMsg Source # 
Instance details

Defined in Calamity.Gateway.Types

Generic ShardMsg Source # 
Instance details

Defined in Calamity.Gateway.Types

Associated Types

type Rep ShardMsg :: Type -> Type #

Methods

from :: ShardMsg -> Rep ShardMsg x #

to :: Rep ShardMsg x -> ShardMsg #

type Rep ShardMsg Source # 
Instance details

Defined in Calamity.Gateway.Types

data ReceivedDiscordMessage Source #

Instances

Instances details
Show ReceivedDiscordMessage Source # 
Instance details

Defined in Calamity.Gateway.Types

Generic ReceivedDiscordMessage Source # 
Instance details

Defined in Calamity.Gateway.Types

Associated Types

type Rep ReceivedDiscordMessage :: Type -> Type #

FromJSON ReceivedDiscordMessage Source # 
Instance details

Defined in Calamity.Gateway.Types

Methods

parseJSON :: Value -> Parser ReceivedDiscordMessage

parseJSONList :: Value -> Parser [ReceivedDiscordMessage]

type Rep ReceivedDiscordMessage Source # 
Instance details

Defined in Calamity.Gateway.Types

type Rep ReceivedDiscordMessage = D1 ('MetaData "ReceivedDiscordMessage" "Calamity.Gateway.Types" "calamity-0.1.14.3-inplace" 'False) ((C1 ('MetaCons "EvtDispatch" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 Int) :*: S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 DispatchData)) :+: (C1 ('MetaCons "HeartBeatReq" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "Reconnect" 'PrefixI 'False) (U1 :: Type -> Type))) :+: (C1 ('MetaCons "InvalidSession" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 Bool)) :+: (C1 ('MetaCons "Hello" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 Int)) :+: C1 ('MetaCons "HeartBeatAck" 'PrefixI 'False) (U1 :: Type -> Type))))

data SentDiscordMessage Source #

Instances

Instances details
Show SentDiscordMessage Source # 
Instance details

Defined in Calamity.Gateway.Types

Generic SentDiscordMessage Source # 
Instance details

Defined in Calamity.Gateway.Types

Associated Types

type Rep SentDiscordMessage :: Type -> Type #

ToJSON SentDiscordMessage Source # 
Instance details

Defined in Calamity.Gateway.Types

type Rep SentDiscordMessage Source # 
Instance details

Defined in Calamity.Gateway.Types

data DispatchType Source #

Instances

Instances details
Enum DispatchType Source # 
Instance details

Defined in Calamity.Gateway.Types

Eq DispatchType Source # 
Instance details

Defined in Calamity.Gateway.Types

Show DispatchType Source # 
Instance details

Defined in Calamity.Gateway.Types

Generic DispatchType Source # 
Instance details

Defined in Calamity.Gateway.Types

Associated Types

type Rep DispatchType :: Type -> Type #

FromJSON DispatchType Source # 
Instance details

Defined in Calamity.Gateway.Types

Methods

parseJSON :: Value -> Parser DispatchType

parseJSONList :: Value -> Parser [DispatchType]

ToJSON DispatchType Source # 
Instance details

Defined in Calamity.Gateway.Types

Methods

toJSON :: DispatchType -> Value

toEncoding :: DispatchType -> Encoding

toJSONList :: [DispatchType] -> Value

toEncodingList :: [DispatchType] -> Encoding

type Rep DispatchType Source # 
Instance details

Defined in Calamity.Gateway.Types

type Rep DispatchType = D1 ('MetaData "DispatchType" "Calamity.Gateway.Types" "calamity-0.1.14.3-inplace" 'False) (((((C1 ('MetaCons "READY" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "RESUMED" 'PrefixI 'False) (U1 :: Type -> Type)) :+: (C1 ('MetaCons "CHANNEL_CREATE" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "CHANNEL_UPDATE" 'PrefixI 'False) (U1 :: Type -> Type))) :+: ((C1 ('MetaCons "CHANNEL_DELETE" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "CHANNEL_PINS_UPDATE" 'PrefixI 'False) (U1 :: Type -> Type)) :+: (C1 ('MetaCons "GUILD_CREATE" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "GUILD_UPDATE" 'PrefixI 'False) (U1 :: Type -> Type)))) :+: (((C1 ('MetaCons "GUILD_DELETE" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "GUILD_BAN_ADD" 'PrefixI 'False) (U1 :: Type -> Type)) :+: (C1 ('MetaCons "GUILD_BAN_REMOVE" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "GUILD_EMOJIS_UPDATE" 'PrefixI 'False) (U1 :: Type -> Type))) :+: ((C1 ('MetaCons "GUILD_INTEGRATIONS_UPDATE" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "GUILD_MEMBER_ADD" 'PrefixI 'False) (U1 :: Type -> Type)) :+: (C1 ('MetaCons "GUILD_MEMBER_REMOVE" 'PrefixI 'False) (U1 :: Type -> Type) :+: (C1 ('MetaCons "GUILD_MEMBER_UPDATE" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "GUILD_MEMBERS_CHUNK" 'PrefixI 'False) (U1 :: Type -> Type)))))) :+: ((((C1 ('MetaCons "GUILD_ROLE_CREATE" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "GUILD_ROLE_UPDATE" 'PrefixI 'False) (U1 :: Type -> Type)) :+: (C1 ('MetaCons "GUILD_ROLE_DELETE" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "INVITE_CREATE" 'PrefixI 'False) (U1 :: Type -> Type))) :+: ((C1 ('MetaCons "INVITE_DELETE" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "MESSAGE_CREATE" 'PrefixI 'False) (U1 :: Type -> Type)) :+: (C1 ('MetaCons "MESSAGE_UPDATE" 'PrefixI 'False) (U1 :: Type -> Type) :+: (C1 ('MetaCons "MESSAGE_DELETE" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "MESSAGE_DELETE_BULK" 'PrefixI 'False) (U1 :: Type -> Type))))) :+: (((C1 ('MetaCons "MESSAGE_REACTION_ADD" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "MESSAGE_REACTION_REMOVE" 'PrefixI 'False) (U1 :: Type -> Type)) :+: (C1 ('MetaCons "MESSAGE_REACTION_REMOVE_ALL" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "PRESENCE_UPDATE" 'PrefixI 'False) (U1 :: Type -> Type))) :+: ((C1 ('MetaCons "TYPING_START" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "USER_UPDATE" 'PrefixI 'False) (U1 :: Type -> Type)) :+: (C1 ('MetaCons "VOICE_STATE_UPDATE" 'PrefixI 'False) (U1 :: Type -> Type) :+: (C1 ('MetaCons "VOICE_SERVER_UPDATE" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "WEBHOOKS_UPDATE" 'PrefixI 'False) (U1 :: Type -> Type)))))))

data IdentifyData Source #

Instances

Instances details
Show IdentifyData Source # 
Instance details

Defined in Calamity.Gateway.Types

Generic IdentifyData Source # 
Instance details

Defined in Calamity.Gateway.Types

Associated Types

type Rep IdentifyData :: Type -> Type #

ToJSON IdentifyData Source # 
Instance details

Defined in Calamity.Gateway.Types

Methods

toJSON :: IdentifyData -> Value

toEncoding :: IdentifyData -> Encoding

toJSONList :: [IdentifyData] -> Value

toEncodingList :: [IdentifyData] -> Encoding

type Rep IdentifyData Source # 
Instance details

Defined in Calamity.Gateway.Types

data StatusUpdateData Source #

Constructors

StatusUpdateData 

Fields

Instances

Instances details
Show StatusUpdateData Source # 
Instance details

Defined in Calamity.Gateway.Types

Generic StatusUpdateData Source # 
Instance details

Defined in Calamity.Gateway.Types

Associated Types

type Rep StatusUpdateData :: Type -> Type #

ToJSON StatusUpdateData Source # 
Instance details

Defined in Calamity.Gateway.Types

type Rep StatusUpdateData Source # 
Instance details

Defined in Calamity.Gateway.Types

type Rep StatusUpdateData = D1 ('MetaData "StatusUpdateData" "Calamity.Gateway.Types" "calamity-0.1.14.3-inplace" 'False) (C1 ('MetaCons "StatusUpdateData" 'PrefixI 'True) ((S1 ('MetaSel ('Just "since") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 (Maybe Integer)) :*: S1 ('MetaSel ('Just "game") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 (Maybe Value))) :*: (S1 ('MetaSel ('Just "status") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 Text) :*: S1 ('MetaSel ('Just "afk") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 Bool))))

data ResumeData Source #

Constructors

ResumeData 

Fields

Instances

Instances details
Show ResumeData Source # 
Instance details

Defined in Calamity.Gateway.Types

Generic ResumeData Source # 
Instance details

Defined in Calamity.Gateway.Types

Associated Types

type Rep ResumeData :: Type -> Type #

FromJSON ResumeData Source # 
Instance details

Defined in Calamity.Gateway.Types

Methods

parseJSON :: Value -> Parser ResumeData

parseJSONList :: Value -> Parser [ResumeData]

ToJSON ResumeData Source # 
Instance details

Defined in Calamity.Gateway.Types

Methods

toJSON :: ResumeData -> Value

toEncoding :: ResumeData -> Encoding

toJSONList :: [ResumeData] -> Value

toEncodingList :: [ResumeData] -> Encoding

type Rep ResumeData Source # 
Instance details

Defined in Calamity.Gateway.Types

type Rep ResumeData = D1 ('MetaData "ResumeData" "Calamity.Gateway.Types" "calamity-0.1.14.3-inplace" 'False) (C1 ('MetaCons "ResumeData" 'PrefixI 'True) (S1 ('MetaSel ('Just "token") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 Text) :*: (S1 ('MetaSel ('Just "sessionID") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 Text) :*: S1 ('MetaSel ('Just "seq") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 Int))))

data RequestGuildMembersData Source #

data IdentifyProps Source #

Constructors

IdentifyProps 

Fields

Instances

Instances details
Show IdentifyProps Source # 
Instance details

Defined in Calamity.Gateway.Types

Generic IdentifyProps Source # 
Instance details

Defined in Calamity.Gateway.Types

Associated Types

type Rep IdentifyProps :: Type -> Type #

ToJSON IdentifyProps Source # 
Instance details

Defined in Calamity.Gateway.Types

Methods

toJSON :: IdentifyProps -> Value

toEncoding :: IdentifyProps -> Encoding

toJSONList :: [IdentifyProps] -> Value

toEncodingList :: [IdentifyProps] -> Encoding

type Rep IdentifyProps Source # 
Instance details

Defined in Calamity.Gateway.Types

type Rep IdentifyProps = D1 ('MetaData "IdentifyProps" "Calamity.Gateway.Types" "calamity-0.1.14.3-inplace" 'False) (C1 ('MetaCons "IdentifyProps" 'PrefixI 'True) (S1 ('MetaSel ('Just "browser") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 Text) :*: S1 ('MetaSel ('Just "device") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 Text)))

data ControlMessage Source #

Instances

Instances details
Show ControlMessage Source # 
Instance details

Defined in Calamity.Gateway.Types

Generic ControlMessage Source # 
Instance details

Defined in Calamity.Gateway.Types

Associated Types

type Rep ControlMessage :: Type -> Type #

type Rep ControlMessage Source # 
Instance details

Defined in Calamity.Gateway.Types

type Rep ControlMessage = D1 ('MetaData "ControlMessage" "Calamity.Gateway.Types" "calamity-0.1.14.3-inplace" 'False) (C1 ('MetaCons "RestartShard" 'PrefixI 'False) (U1 :: Type -> Type) :+: (C1 ('MetaCons "ShutDownShard" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "SendPresence" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 StatusUpdateData))))

data ShardFlowControl Source #

Instances

Instances details
Show ShardFlowControl Source # 
Instance details

Defined in Calamity.Gateway.Types

Generic ShardFlowControl Source # 
Instance details

Defined in Calamity.Gateway.Types

Associated Types

type Rep ShardFlowControl :: Type -> Type #

TextShow ShardFlowControl Source # 
Instance details

Defined in Calamity.Gateway.Types

type Rep ShardFlowControl Source # 
Instance details

Defined in Calamity.Gateway.Types

type Rep ShardFlowControl = D1 ('MetaData "ShardFlowControl" "Calamity.Gateway.Types" "calamity-0.1.14.3-inplace" 'False) (C1 ('MetaCons "ShardFlowRestart" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "ShardFlowShutDown" 'PrefixI 'False) (U1 :: Type -> Type))

data Shard Source #

data ShardState Source #

Constructors

ShardState 

Fields

Instances

Instances details
Generic ShardState Source # 
Instance details

Defined in Calamity.Gateway.Types

Associated Types

type Rep ShardState :: Type -> Type #

type Rep ShardState Source # 
Instance details

Defined in Calamity.Gateway.Types