{-# 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.DFAReporting.DirectorySiteContacts.Get
(
DirectorySiteContactsGetResource
, directorySiteContactsGet
, DirectorySiteContactsGet
, dscgProFileId
, dscgId
) where
import Network.Google.DFAReporting.Types
import Network.Google.Prelude
type DirectorySiteContactsGetResource =
"dfareporting" :>
"v3.2" :>
"userprofiles" :>
Capture "profileId" (Textual Int64) :>
"directorySiteContacts" :>
Capture "id" (Textual Int64) :>
QueryParam "alt" AltJSON :>
Get '[JSON] DirectorySiteContact
data DirectorySiteContactsGet = DirectorySiteContactsGet'
{ _dscgProFileId :: !(Textual Int64)
, _dscgId :: !(Textual Int64)
} deriving (Eq,Show,Data,Typeable,Generic)
directorySiteContactsGet
:: Int64
-> Int64
-> DirectorySiteContactsGet
directorySiteContactsGet pDscgProFileId_ pDscgId_ =
DirectorySiteContactsGet'
{ _dscgProFileId = _Coerce # pDscgProFileId_
, _dscgId = _Coerce # pDscgId_
}
dscgProFileId :: Lens' DirectorySiteContactsGet Int64
dscgProFileId
= lens _dscgProFileId
(\ s a -> s{_dscgProFileId = a})
. _Coerce
dscgId :: Lens' DirectorySiteContactsGet Int64
dscgId
= lens _dscgId (\ s a -> s{_dscgId = a}) . _Coerce
instance GoogleRequest DirectorySiteContactsGet where
type Rs DirectorySiteContactsGet =
DirectorySiteContact
type Scopes DirectorySiteContactsGet =
'["https://www.googleapis.com/auth/dfatrafficking"]
requestClient DirectorySiteContactsGet'{..}
= go _dscgProFileId _dscgId (Just AltJSON)
dFAReportingService
where go
= buildClient
(Proxy :: Proxy DirectorySiteContactsGetResource)
mempty