{-# 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.AdExchangeSeller.Accounts.CustomChannels.Get
(
AccountsCustomChannelsGetResource
, accountsCustomChannelsGet
, AccountsCustomChannelsGet
, accgCustomChannelId
, accgAdClientId
, accgAccountId
) where
import Network.Google.AdExchangeSeller.Types
import Network.Google.Prelude
type AccountsCustomChannelsGetResource =
"adexchangeseller" :>
"v2.0" :>
"accounts" :>
Capture "accountId" Text :>
"adclients" :>
Capture "adClientId" Text :>
"customchannels" :>
Capture "customChannelId" Text :>
QueryParam "alt" AltJSON :> Get '[JSON] CustomChannel
data AccountsCustomChannelsGet = AccountsCustomChannelsGet'
{ _accgCustomChannelId :: !Text
, _accgAdClientId :: !Text
, _accgAccountId :: !Text
} deriving (Eq,Show,Data,Typeable,Generic)
accountsCustomChannelsGet
:: Text
-> Text
-> Text
-> AccountsCustomChannelsGet
accountsCustomChannelsGet pAccgCustomChannelId_ pAccgAdClientId_ pAccgAccountId_ =
AccountsCustomChannelsGet'
{ _accgCustomChannelId = pAccgCustomChannelId_
, _accgAdClientId = pAccgAdClientId_
, _accgAccountId = pAccgAccountId_
}
accgCustomChannelId :: Lens' AccountsCustomChannelsGet Text
accgCustomChannelId
= lens _accgCustomChannelId
(\ s a -> s{_accgCustomChannelId = a})
accgAdClientId :: Lens' AccountsCustomChannelsGet Text
accgAdClientId
= lens _accgAdClientId
(\ s a -> s{_accgAdClientId = a})
accgAccountId :: Lens' AccountsCustomChannelsGet Text
accgAccountId
= lens _accgAccountId
(\ s a -> s{_accgAccountId = a})
instance GoogleRequest AccountsCustomChannelsGet
where
type Rs AccountsCustomChannelsGet = CustomChannel
type Scopes AccountsCustomChannelsGet =
'["https://www.googleapis.com/auth/adexchange.seller",
"https://www.googleapis.com/auth/adexchange.seller.readonly"]
requestClient AccountsCustomChannelsGet'{..}
= go _accgAccountId _accgAdClientId
_accgCustomChannelId
(Just AltJSON)
adExchangeSellerService
where go
= buildClient
(Proxy :: Proxy AccountsCustomChannelsGetResource)
mempty