{-# 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.Directory.VerificationCodes.Generate
(
VerificationCodesGenerateResource
, verificationCodesGenerate
, VerificationCodesGenerate
, vcgUserKey
) where
import Network.Google.Directory.Types
import Network.Google.Prelude
type VerificationCodesGenerateResource =
"admin" :>
"directory" :>
"v1" :>
"users" :>
Capture "userKey" Text :>
"verificationCodes" :>
"generate" :>
QueryParam "alt" AltJSON :> Post '[JSON] ()
newtype VerificationCodesGenerate = VerificationCodesGenerate'
{ _vcgUserKey :: Text
} deriving (Eq,Show,Data,Typeable,Generic)
verificationCodesGenerate
:: Text
-> VerificationCodesGenerate
verificationCodesGenerate pVcgUserKey_ =
VerificationCodesGenerate'
{ _vcgUserKey = pVcgUserKey_
}
vcgUserKey :: Lens' VerificationCodesGenerate Text
vcgUserKey
= lens _vcgUserKey (\ s a -> s{_vcgUserKey = a})
instance GoogleRequest VerificationCodesGenerate
where
type Rs VerificationCodesGenerate = ()
type Scopes VerificationCodesGenerate =
'["https://www.googleapis.com/auth/admin.directory.user.security"]
requestClient VerificationCodesGenerate'{..}
= go _vcgUserKey (Just AltJSON) directoryService
where go
= buildClient
(Proxy :: Proxy VerificationCodesGenerateResource)
mempty