{-# 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.Placements.Get
(
PlacementsGetResource
, placementsGet
, PlacementsGet
, pgProFileId
, pgId
) where
import Network.Google.DFAReporting.Types
import Network.Google.Prelude
type PlacementsGetResource =
"dfareporting" :>
"v3.2" :>
"userprofiles" :>
Capture "profileId" (Textual Int64) :>
"placements" :>
Capture "id" (Textual Int64) :>
QueryParam "alt" AltJSON :> Get '[JSON] Placement
data PlacementsGet = PlacementsGet'
{ _pgProFileId :: !(Textual Int64)
, _pgId :: !(Textual Int64)
} deriving (Eq,Show,Data,Typeable,Generic)
placementsGet
:: Int64
-> Int64
-> PlacementsGet
placementsGet pPgProFileId_ pPgId_ =
PlacementsGet'
{ _pgProFileId = _Coerce # pPgProFileId_
, _pgId = _Coerce # pPgId_
}
pgProFileId :: Lens' PlacementsGet Int64
pgProFileId
= lens _pgProFileId (\ s a -> s{_pgProFileId = a}) .
_Coerce
pgId :: Lens' PlacementsGet Int64
pgId = lens _pgId (\ s a -> s{_pgId = a}) . _Coerce
instance GoogleRequest PlacementsGet where
type Rs PlacementsGet = Placement
type Scopes PlacementsGet =
'["https://www.googleapis.com/auth/dfatrafficking"]
requestClient PlacementsGet'{..}
= go _pgProFileId _pgId (Just AltJSON)
dFAReportingService
where go
= buildClient (Proxy :: Proxy PlacementsGetResource)
mempty