{-# 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.AdSense.Accounts.Savedadstyles.Get
(
AccountsSavedadstylesGetResource
, accountsSavedadstylesGet
, AccountsSavedadstylesGet
, asgSavedAdStyleId
, asgAccountId
) where
import Network.Google.AdSense.Types
import Network.Google.Prelude
type AccountsSavedadstylesGetResource =
"adsense" :>
"v1.4" :>
"accounts" :>
Capture "accountId" Text :>
"savedadstyles" :>
Capture "savedAdStyleId" Text :>
QueryParam "alt" AltJSON :> Get '[JSON] SavedAdStyle
data AccountsSavedadstylesGet = AccountsSavedadstylesGet'
{ _asgSavedAdStyleId :: !Text
, _asgAccountId :: !Text
} deriving (Eq,Show,Data,Typeable,Generic)
accountsSavedadstylesGet
:: Text
-> Text
-> AccountsSavedadstylesGet
accountsSavedadstylesGet pAsgSavedAdStyleId_ pAsgAccountId_ =
AccountsSavedadstylesGet'
{ _asgSavedAdStyleId = pAsgSavedAdStyleId_
, _asgAccountId = pAsgAccountId_
}
asgSavedAdStyleId :: Lens' AccountsSavedadstylesGet Text
asgSavedAdStyleId
= lens _asgSavedAdStyleId
(\ s a -> s{_asgSavedAdStyleId = a})
asgAccountId :: Lens' AccountsSavedadstylesGet Text
asgAccountId
= lens _asgAccountId (\ s a -> s{_asgAccountId = a})
instance GoogleRequest AccountsSavedadstylesGet where
type Rs AccountsSavedadstylesGet = SavedAdStyle
type Scopes AccountsSavedadstylesGet =
'["https://www.googleapis.com/auth/adsense",
"https://www.googleapis.com/auth/adsense.readonly"]
requestClient AccountsSavedadstylesGet'{..}
= go _asgAccountId _asgSavedAdStyleId (Just AltJSON)
adSenseService
where go
= buildClient
(Proxy :: Proxy AccountsSavedadstylesGetResource)
mempty