calamity-0.8.0.0: A library for writing discord bots in haskell
Safe HaskellSafe-Inferred
LanguageHaskell2010

Calamity.HTTP.Internal.Route

Description

The route type Why I did this I don't know

Synopsis

Documentation

giveID :: forall t reqs. Typeable t => Snowflake t -> RouteBuilder reqs -> RouteBuilder ('('IDRequirement t, 'Satisfied) ': reqs) Source #

giveParam :: forall (s :: Symbol) reqs. KnownSymbol s => Text -> RouteBuilder reqs -> RouteBuilder ('('PSRequirement s, 'Satisfied) ': reqs) Source #

buildRoute :: forall (reqs :: [(RequirementType, RouteRequirement)]). EnsureFulfilled reqs => RouteBuilder reqs -> Route Source #

data RouteBuilder (reqstate :: [(RequirementType, RouteRequirement)]) Source #

data Route Source #

Instances

Instances details
Show Route Source # 
Instance details

Defined in Calamity.HTTP.Internal.Route

Methods

showsPrec :: Int -> Route -> ShowS #

show :: Route -> String #

showList :: [Route] -> ShowS #

(k ~ A_Lens, a ~ Maybe (Snowflake Channel), b ~ Maybe (Snowflake Channel)) => LabelOptic "channelID" k Route Route a b Source # 
Instance details

Defined in Calamity.HTTP.Internal.Route

Methods

labelOptic :: Optic k NoIx Route Route a b #

(k ~ A_Lens, a ~ Maybe (Snowflake Guild), b ~ Maybe (Snowflake Guild)) => LabelOptic "guildID" k Route Route a b Source # 
Instance details

Defined in Calamity.HTTP.Internal.Route

Methods

labelOptic :: Optic k NoIx Route Route a b #

(k ~ A_Lens, a ~ Text, b ~ Text) => LabelOptic "key" k Route Route a b Source # 
Instance details

Defined in Calamity.HTTP.Internal.Route

Methods

labelOptic :: Optic k NoIx Route Route a b #

(k ~ A_Lens, a ~ Url 'Https, b ~ Url 'Https) => LabelOptic "path" k Route Route a b Source # 
Instance details

Defined in Calamity.HTTP.Internal.Route

Methods

labelOptic :: Optic k NoIx Route Route a b #

newtype S Source #

A static string fragment of a route

Constructors

S Text 

Instances

Instances details
RouteFragmentable S reqs Source # 
Instance details

Defined in Calamity.HTTP.Internal.Route

Associated Types

type ConsRes S reqs Source #

Methods

(//) :: RouteBuilder reqs -> S -> ConsRes S reqs Source #

type ConsRes S reqs Source # 
Instance details

Defined in Calamity.HTTP.Internal.Route

type ConsRes S reqs = RouteBuilder reqs

data PS (s :: Symbol) Source #

A parameterised string fragment of a route

Constructors

PS 

Instances

Instances details
KnownSymbol s => RouteFragmentable (PS s) reqs Source # 
Instance details

Defined in Calamity.HTTP.Internal.Route

Associated Types

type ConsRes (PS s) reqs Source #

Methods

(//) :: RouteBuilder reqs -> PS s -> ConsRes (PS s) reqs Source #

type ConsRes (PS s) reqs Source # 
Instance details

Defined in Calamity.HTTP.Internal.Route

type ConsRes (PS s) reqs

data ID a Source #

An id fragment of a route

Constructors

ID 

Instances

Instances details
Typeable a => RouteFragmentable (ID a) reqs Source # 
Instance details

Defined in Calamity.HTTP.Internal.Route

Associated Types

type ConsRes (ID a) reqs Source #

Methods

(//) :: RouteBuilder reqs -> ID a -> ConsRes (ID a) reqs Source #

type ConsRes (ID a) reqs Source # 
Instance details

Defined in Calamity.HTTP.Internal.Route

type ConsRes (ID a) reqs

class Typeable a => RouteFragmentable a reqs where Source #

Associated Types

type ConsRes a reqs Source #

Methods

(//) :: RouteBuilder reqs -> a -> ConsRes a reqs infixl 5 Source #

Instances

Instances details
RouteFragmentable S reqs Source # 
Instance details

Defined in Calamity.HTTP.Internal.Route

Associated Types

type ConsRes S reqs Source #

Methods

(//) :: RouteBuilder reqs -> S -> ConsRes S reqs Source #

KnownSymbol s => RouteFragmentable (PS s) reqs Source # 
Instance details

Defined in Calamity.HTTP.Internal.Route

Associated Types

type ConsRes (PS s) reqs Source #

Methods

(//) :: RouteBuilder reqs -> PS s -> ConsRes (PS s) reqs Source #

Typeable a => RouteFragmentable (ID a) reqs Source # 
Instance details

Defined in Calamity.HTTP.Internal.Route

Associated Types

type ConsRes (ID a) reqs Source #

Methods

(//) :: RouteBuilder reqs -> ID a -> ConsRes (ID a) reqs Source #