{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE FlexibleInstances #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators #-}
{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
{-# OPTIONS_GHC -fno-warn-unused-binds #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
module Network.Google.Resource.GamesManagement.Scores.Reset
(
ScoresResetResource
, scoresReset
, ScoresReset
, srLeaderboardId
) where
import Network.Google.GamesManagement.Types
import Network.Google.Prelude
type ScoresResetResource =
"games" :>
"v1management" :>
"leaderboards" :>
Capture "leaderboardId" Text :>
"scores" :>
"reset" :>
QueryParam "alt" AltJSON :>
Post '[JSON] PlayerScoreResetResponse
newtype ScoresReset = ScoresReset'
{ _srLeaderboardId :: Text
} deriving (Eq,Show,Data,Typeable,Generic)
scoresReset
:: Text
-> ScoresReset
scoresReset pSrLeaderboardId_ =
ScoresReset'
{ _srLeaderboardId = pSrLeaderboardId_
}
srLeaderboardId :: Lens' ScoresReset Text
srLeaderboardId
= lens _srLeaderboardId
(\ s a -> s{_srLeaderboardId = a})
instance GoogleRequest ScoresReset where
type Rs ScoresReset = PlayerScoreResetResponse
type Scopes ScoresReset =
'["https://www.googleapis.com/auth/games"]
requestClient ScoresReset'{..}
= go _srLeaderboardId (Just AltJSON)
gamesManagementService
where go
= buildClient (Proxy :: Proxy ScoresResetResource)
mempty