{-# 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.Games.Pushtokens.Update
(
PushtokensUpdateResource
, pushtokensUpdate
, PushtokensUpdate
, puPayload
) where
import Network.Google.Games.Types
import Network.Google.Prelude
type PushtokensUpdateResource =
"games" :>
"v1" :>
"pushtokens" :>
QueryParam "alt" AltJSON :>
ReqBody '[JSON] PushToken :> Put '[JSON] ()
newtype PushtokensUpdate = PushtokensUpdate'
{ _puPayload :: PushToken
} deriving (Eq,Show,Data,Typeable,Generic)
pushtokensUpdate
:: PushToken
-> PushtokensUpdate
pushtokensUpdate pPuPayload_ =
PushtokensUpdate'
{ _puPayload = pPuPayload_
}
puPayload :: Lens' PushtokensUpdate PushToken
puPayload
= lens _puPayload (\ s a -> s{_puPayload = a})
instance GoogleRequest PushtokensUpdate where
type Rs PushtokensUpdate = ()
type Scopes PushtokensUpdate =
'["https://www.googleapis.com/auth/games"]
requestClient PushtokensUpdate'{..}
= go (Just AltJSON) _puPayload gamesService
where go
= buildClient
(Proxy :: Proxy PushtokensUpdateResource)
mempty