License | MIT |
---|---|
Safe Haskell | None |
Language | Haskell2010 |
Documentation
type WebApi = "v1a" :> (("client" :> (("auth" :> (ReqBody '[JSON] ClientAuthRequest :> Post '[JSON] ClientAuthResponse)) :<|> (("match" :> ((AuthProtect ClientToken :> (ReqBody '[JSON] MatchRequest :> Post '[JSON] MatchResponse)) :<|> ((AuthProtect ClientToken :> (Capture "matchToken" (InternalToken MatchToken) :> Get '[JSON] MatchStatusResponse)) :<|> (AuthProtect ClientToken :> (Capture "matchToken" (InternalToken MatchToken) :> Delete '[JSON] MatchCancelResponse))))) :<|> (("session" :> (Capture "sessionToken" (InternalToken SessionToken) :> ("result" :> (AuthProtect ClientToken :> (ReqBody '[JSON] SessionResultRequest :> Post '[JSON] ()))))) :<|> ("info" :> ("stats" :> (AuthProtect ClientToken :> Get '[JSON] UserStats))))))) :<|> ("server" :> (("match" :> (ReqBody '[JSON] ServerMatchRequest :> Post '[JSON] ServerMatchResponse)) :<|> ("session" :> (Capture "serverSessionToken" (InternalToken ServerSessionToken) :> ("result" :> (ReqBody '[JSON] ServerSessionResultRequest :> Post '[JSON] ()))))))) Source #
data ClientAuthRequest Source #
Instances
data ClientAuthResponse Source #
Instances
data MatchRequest Source #
Instances
data MatchResponse Source #
Instances
Generic MatchResponse Source # | |
Defined in BattlePlace.WebApi type Rep MatchResponse :: * -> * # from :: MatchResponse -> Rep MatchResponse x # to :: Rep MatchResponse x -> MatchResponse # | |
ToJSON MatchResponse Source # | |
Defined in BattlePlace.WebApi toJSON :: MatchResponse -> Value # toEncoding :: MatchResponse -> Encoding # toJSONList :: [MatchResponse] -> Value # toEncodingList :: [MatchResponse] -> Encoding # | |
FromJSON MatchResponse Source # | |
Defined in BattlePlace.WebApi parseJSON :: Value -> Parser MatchResponse # parseJSONList :: Value -> Parser [MatchResponse] # | |
type Rep MatchResponse Source # | |
Defined in BattlePlace.WebApi type Rep MatchResponse = D1 (MetaData "MatchResponse" "BattlePlace.WebApi" "battleplace-0.1.0.6-EVfBQWt7RHd8mmLWazZmlN" False) (C1 (MetaCons "MatchResponse" PrefixI True) (S1 (MetaSel (Just "matchResponse_matchToken") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 (InternalToken MatchToken)))) |
data MatchStatusResponse Source #
MatchStatusResponse_notFound | |
MatchStatusResponse_inProgress | |
MatchStatusResponse_matched | |
MatchStatusResponse_failed | |
MatchStatusResponse_cleaned | Match status was cleaned. Normallly this status should not be visible to clients, it's here just in case. |
Instances
data MatchCancelResponse Source #
Instances
Generic MatchCancelResponse Source # | |
Defined in BattlePlace.WebApi type Rep MatchCancelResponse :: * -> * # from :: MatchCancelResponse -> Rep MatchCancelResponse x # to :: Rep MatchCancelResponse x -> MatchCancelResponse # | |
ToJSON MatchCancelResponse Source # | |
Defined in BattlePlace.WebApi toJSON :: MatchCancelResponse -> Value # toEncoding :: MatchCancelResponse -> Encoding # toJSONList :: [MatchCancelResponse] -> Value # toEncodingList :: [MatchCancelResponse] -> Encoding # | |
FromJSON MatchCancelResponse Source # | |
Defined in BattlePlace.WebApi parseJSON :: Value -> Parser MatchCancelResponse # parseJSONList :: Value -> Parser [MatchCancelResponse] # | |
type Rep MatchCancelResponse Source # | |
Defined in BattlePlace.WebApi |
data MatchPlayer Source #
Instances
data MatchServer Source #
Instances
data SessionResultRequest Source #
Instances
data ServerMatchRequest Source #
Instances
data ServerMatchResponse Source #
Instances
data ServerSessionResultRequest Source #
Instances
Generic ServerSessionResultRequest Source # | |
Defined in BattlePlace.WebApi type Rep ServerSessionResultRequest :: * -> * # | |
ToJSON ServerSessionResultRequest Source # | |
Defined in BattlePlace.WebApi | |
FromJSON ServerSessionResultRequest Source # | |
Defined in BattlePlace.WebApi | |
type Rep ServerSessionResultRequest Source # | |
Defined in BattlePlace.WebApi type Rep ServerSessionResultRequest = D1 (MetaData "ServerSessionResultRequest" "BattlePlace.WebApi" "battleplace-0.1.0.6-EVfBQWt7RHd8mmLWazZmlN" False) (C1 (MetaCons "ServerSessionResultRequest_finished" PrefixI True) (S1 (MetaSel (Just "serverSessionResultRequest_ranks") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 (Vector Int))) :+: C1 (MetaCons "ServerSessionResultRequest_cancelled" PrefixI False) (U1 :: * -> *)) |
data ServerSession Source #